Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: Hash of hashes

by choroba (Abbot)
on Apr 06, 2013 at 00:10 UTC ( #1027233=note: print w/ replies, xml ) Need Help??


in reply to Hash of hashes

If your question was how to read the data into the hash, here is one possible way:

#!/usr/bin/perl use warnings; use strict; my $exe; my %hash; while (<>) { my ($quotas, $start, $finish) = split ' '; if (not defined $finish) { $exe = $quotas; <>; # Skip the following header. } else { $hash{$exe}{$quotas} = [ $start, $finish ]; } } print $hash{'ww.exe'}{def}[0];
لսႽ ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ


Comment on Re: Hash of hashes
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1027233]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (11)
As of 2014-11-24 14:14 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My preferred Perl binaries come from:














    Results (141 votes), past polls