![]() |
|
P is for Practical | |
PerlMonks |
Re^2: Golf: reverse sort /etc/passwd by UIDby tobyink (Abbot) |
on Feb 06, 2013 at 14:30 UTC ( #1017446=note: print w/replies, xml ) | Need Help?? |
Nice trick with split. Can be improved somewhat...
Or even:
Update: or with a sufficiently outdated Perl...
(split in void context was deprecated in 5.10 and dropped in 5.12 IIRC.)
package Cow { use Moo; has name => (is => 'lazy', default => sub { 'Mooington' }) } say Cow->new->name
In Section
Meditations
|
|