marlowvoltron has asked for the wisdom of the Perl Monks concerning the following question:
Ok monks, so I have perl going through directories, and creating hashes out of .tifs it finds. The keys are the dates and the values are the .tifs (to keep them associated). So these hashes are always differing in size.
How do I create a loop where I have the first key subtract from the next key, so I can calculate the difference in days? i will want it to do this for every subsequent key. So if I have 4 keys, I will want element 0 to subtract from 1, 2, & 3. Then have element 1 subtract from 2 & 3. And then element 2 to subtract from 3.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Hash Math
by kennethk (Abbot) on Jun 09, 2014 at 19:48 UTC | |
by marlowvoltron (Novice) on Jun 09, 2014 at 20:59 UTC | |
by kennethk (Abbot) on Jun 09, 2014 at 23:40 UTC | |
|
Re: Hash Math
by boftx (Deacon) on Jun 09, 2014 at 23:08 UTC | |
|
Re: Hash Math
by locked_user sundialsvc4 (Abbot) on Jun 09, 2014 at 20:01 UTC | |
by marlowvoltron (Novice) on Jun 09, 2014 at 20:36 UTC | |
by Cristoforo (Curate) on Jun 10, 2014 at 02:16 UTC | |
by perlfan (Parson) on Jun 10, 2014 at 14:25 UTC |