in reply to Re: Sorting of numbers using arraysin thread Sorting of numbers using arrays
map { scalar reverse } @values
use strict; use warnings; my @values = qw(1452 6351 5892); @values = map { scalar reverse } @values; print "@values "; [download]
prints 2541 1536 2985, so it's just reverting but not sorting the strings. I just wanted to point ot that you can use sort.