use Devel::Size qw(total_size); # code by perrin my $size_rec_hash = total_size(\%record); my $size_flag_hash = total_size(\%flag); print "Total size: $size_rec_hash + $size_flag_hash =", $size_rec_hash + $size_flag_hash, "\n";
-- Hofmator
Code written by Hofmator and posted on PerlMonks is public domain. It is provided as is with no warranties, express or implied, of any kind. Posted code may not have been tested. Use of posted code is at your own risk.
In reply to Re^3: How to create a compact data structure?
by Hofmator
in thread How to create a compact data structure?
by bart
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |