in reply to Re: Re: Re: Weighting rand()
in thread Weighting rand()
The size of a scalar has a minimum overhead. Anything below about 20 characters (guess) in length requires the same amount of memoryEr, no. A scalar that is only ever used as a number will use less memory than a scalar used as a string (even one of zero length).
$ perl -e 'push @a, 1 for 1..100000; system"ps -flp $$"' .... SZ .... 608 $ perl -e 'push @a, "" for 1..100000; system"ps -flp $$"' .... SZ .... 905
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: Re: Re: Weighting rand()
by BrowserUk (Patriarch) on May 25, 2004 at 11:30 UTC |