Thanks Bryan,

I used unsafeInterleaveIO after I ran into "too many open file handles" error.
Again, I doubt about String since even if I change the number of files to 12000 - the perl program finishes in less than a second.

Regards,
Kashyap


On Tue, Jun 24, 2014 at 9:49 PM, Bryan O'Sullivan <bos@serpentine.com> wrote:

On Tue, Jun 24, 2014 at 9:08 AM, C K Kashyap <ckkashyap@gmail.com> wrote:
Essentially I am trying to open a number of files and printing out their sized by reading them in and computing it's length.

Don't use String, and don't use unsafeInterleaveIO unless you know what you're doing.