in reply to Why does ‘keys’ need a named hash?
Hi ankitpati,
returns list having even number of elements. 'keys' works only on hashes. In your working example %hash is initialized with the list returned by 'map' and then 'keys' can do the job on %hash.map { $_ => 1 } @_
HTH
In Section
Seekers of Perl Wisdom