I know it's removing the duplicate values in an array
No, it isn't.
It is creating a hash called %count where the keys are the stringified values in the array @Clec_id and the values are the number of occurrences of each array value. Then it is printing the keys and values of that hash.
It may be true that keys %count contains the values of the original array with duplicates removed but not guaranteed. For instance, if the array contains references, they won't exist as keys in the hash; only their stringified representation will. Also, the keys of the hash are unlikely to be returned in the same order as the values of the array.
-sauoq "My two cents aren't worth a dime.";
In reply to Re: Can someone Explain 2 lines of code
by sauoq
in thread Can someone Explain 2 lines of code
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |