Linux Today: Linux News On Internet Time.





More on LinuxToday


Unique Sorting Of Lists And Lists Of Lists With Perl For Linux Or Unix

Sep 06, 2008, 08:01 (0 Talkback[s])
(Other stories by Mike Tremell)

[ Thanks to Mike Golvach for this link. ]

"Q. Why the klunky foreach block at the top of the attached code? Shouldn't sorting be simpler?

"A. Actually, sorting data is simpler, but, in this case we were dealing with sorting on two levels, which may not have been readily apparent. The @s_perms array that gets returned from the public domain "permute" subroutine actually contains multiple scalar pseudo-lists.""

Complete Story

Related Stories: