To put those values in an array in sorted order using this technique, I had to do this:
for (sort (map {version->declare($_)} @unsorted_versions)) { push @versions, (sprintf "%s", $_); }
I also added () and {} to help my amateur mind see precedence and the for/sort/map boundaries easier.
In reply to Re^2: Sorting an array containing version numbers
by jffry
in thread Sorting an array containing version numbers
by appu_rajiv
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |