in reply to how array variables are stored in memory
Hello vipsnoida, and welcome to the Monastery!
A quick script shows suggests that array variables are not stored in contiguous memory locations as in C or C++:
16:29 >perl -wE "my @array = qw(a b c); say \$array[$_] for 0 .. 2;" SCALAR(0x27c03c) SCALAR(0x27c15c) SCALAR(0x27c1a4) 16:29 >
But since you never need to do pointer arithmetic in Perl, why do you want to know?
Hope that helps,
| Athanasius <°(((>< contra mundum | Iustus alius egestas vitae, eros Piratica, |
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: how array variables are stored in memory
by davido (Cardinal) on Feb 06, 2014 at 06:51 UTC | |
by Athanasius (Archbishop) on Feb 06, 2014 at 06:58 UTC | |
by davido (Cardinal) on Feb 06, 2014 at 07:14 UTC |