Soham Das wrote:
My agenda actually is two pronged. I have read Beginning Perl and a bit of Intermediate Perl, though was able to solve individual problems, but I was not sure,if I can code myself out of a wet paperbag.So I thought, lets chuck theory. Its better to get hands dirty with some real life code. Actually, the stuff which I am working on is my own problem. Its related to what I do, and I was adviced to do the same thing in Excel, as its much easier. But yes, I got to learn Perl and got to solve my issue ;) So that might explain the reason behind why I dont have much idea on what I happen to be thinking.I am not really sure how to proceed. To put my problem more succinctly a. I have a CSV file b. I am reading and parsing it through Tie::Handle::CSV module c. There is a date column in that csv file d I want to process a hashlist such that each date is mapped to a sequential number. {where I am stuck at, currently} e. I want to use this hash as a way to further process another csv such that I can segregate the contents of the second csv populating/processing two two-dimensional array.
Shawn's Programming Rules #7: When creating data structures: if preserving the order is important, use an array; otherwise use a hash. <http://www.perlfoundation.org/perl5/index.cgi?shawn_h_corey#shawn_s_programming_rules>
Why can't you use the date as a key for the second file and create a hash of arrays or even a hash of hashes?
-- Just my 0.00000002 million dollars worth, Shawn Programming is as much about organization and communication as it is about coding. I like Perl; it's the only language where you can bless your thingy. -- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] http://learn.perl.org/
