develooper Front page | perl.perl6.users | Postings from June 2018

need sort help

Thread Next
From:
ToddAndMargo
Date:
June 9, 2018 00:15
Subject:
need sort help
Message ID:
cb26f518-6a43-851e-4590-8cfd7e5b748e@zoho.com
Hi All,

https://docs.perl6.org/routine/sort

How do I fix this?

$ ls | perl6 -e 'my @x=slurp(); say @x.sort'
(log.06-08-2018_16:07:39.zip
log.06-08-2018_17:07:39.zip
log.07-08-2018_06:07:39.zip
log.07-08-2018_16:07:39.zip
log.12-08-2016_06:07:39.zip
)


2016 should be at the top.


Many thanks,
-T

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About