Home: Need a Custom or Prewritten Perl Program?: I need a program that...:
Code to compare file size in pair from a directory



rushadrena
Novice

Sep 27, 2011, 7:02 AM


Views: 11740
Code to compare file size in pair from a directory

Suppose i have 10 files in a directory.
Then first id like to compare the size of first file with the rest ten and store it in an array.
Then in second pass id like to start with second file and compare it with rest 8 and store the result in the array...and so on.
Please suggest !!!!!!!!


BillKSmith
Veteran

Oct 3, 2011, 4:33 PM


Views: 11628
Re: [rushadrena] Code to compare file size in pair from a directory


Quote
.....store it in an array.



What 'it' should be stored in the array?

Perhaps a hash of hashes would be better than an array (use filenames as keys).
Good Luck,
Bill