I have never used perl before, and I was recommended to use this to write a script for this:
I have a file that has 2 columns like this:
A B
10 33
8 20
30 90
If B falls in a certain range, say 15 < B < 30, I need to store the corresponding value of A, 8 in this case, in some structure (hashtable?)
I have another file that looks like this
C D
34 X
40 Z
8 Y
If the value in C matches the one in our structure, I need to store the corresponding value of D someplace (an array?). In this case, since 8 is present in our structure, I store the value Y.
Am I on the right track or is there a smarter way to do this in perl?
Thanks!
I have a file that has 2 columns like this:
A B
10 33
8 20
30 90
If B falls in a certain range, say 15 < B < 30, I need to store the corresponding value of A, 8 in this case, in some structure (hashtable?)
I have another file that looks like this
C D
34 X
40 Z
8 Y
If the value in C matches the one in our structure, I need to store the corresponding value of D someplace (an array?). In this case, since 8 is present in our structure, I store the value Y.
Am I on the right track or is there a smarter way to do this in perl?
Thanks!
Comment