in reply to Re^2: I need help with opening a directory and reading files in that directory.
in thread I need help with opening a directory and reading files in that directory.
I was also told that you could add as many keys to a hash as you wanted. Is that true?The short answer is yes.
With two caveats, though:
1. Hashes can't have duplicate keys, so that if you have twice the same key in your input, you'll end up with only one entry (probably the last one, depending on how you populate the hash exactly) in your hash.
2. The other limitation is sheer size of the data compared to the available memory on your computer. If you have tens of millions of hashes entries, you might end up at some point with an "out of memory" exception. To give a very rough idea of the limit, with one of the specific servers I am using at work, I can usually store 5 to 8 million hash entries (depending on the size of the keys and values), but usually not much more. But the limitation is only with the memory available on the platform, not with hashes or with Perl in general.
|
|---|