Front page | perl.beginners |
Postings from March 2012
some suggestions
Thread Next
From:
Chris Stinemetz
Date:
March 22, 2012 14:23
Subject:
some suggestions
Message ID:
CA+Hbpzj15ZNqE3fEAshmC6emabtjy6NOZRHT33MEaRiN3gFKLw@mail.gmail.com
I would like to use the number on the left as a key in a hash and use
the number on the right as the value pair to the key. Then print the
values for each hour that have the same key. Maybe this is a good
example for an array of hashes, but I not real sure how to begin. Any
help is greatly appreciated.
Below is the input data:
Hr 12
0001 2
0002 3
0003 1
Hr 13
0001 2
0002 3
0003 1
Hr 14
0001 2
0002 3
0003 1
Desired output below:
12 13 14
0001 2 2 2
0002 3 3 3
0003 1 1 1
Thread Next
-
some suggestions
by Chris Stinemetz