Help for this page

Select Code to Download


  1. or download this
    $ perl -MDevel::Size=total_size -wle'
        my @a;        print total_size(\@a);
    ...
    56   <- Empty
    136  <- With 4 numbers
    72   <- Empty
    
  2. or download this
    $ perl -MDevel::Size=total_size -wle'
        sub foo { my @a; print total_size(\@a); @a=(1,2,3,4); }
    ...
    '
    56   <- Fresh variable
    72   <- Fresh variable