http://qs321.pair.com?node_id=1187137


in reply to Why does ‘keys’ need a named hash?

The document is using the word "named" in the sense of "specified in the calling statement". You can take the keys of an anonymous hash:
use strict; use warnings; my @Uniq = uniq('a', 'b', 'c', 'a', 'b', 'a'); print "@Uniq\n"; sub uniq { return keys %{{map {$_=>1} @_}}; } OUTPUT: c a b

Edit: Revised example to be more like the original problem.

Bill