in reply to Sorting of numbers using arrays
On the off chance that you are looking for a way of sorting a subsection of an array (hard to tell as you give no sample code or data) I offer the following:
use strict; use warnings; my @values = qw(a b c 9 8 7 1 2 3 6 4 5 x y z); @values[3 .. 11] = sort {$a <=> $b} @values[3 .. 11]; print "@values";
Prints:
a b c 1 2 3 4 5 6 7 8 9 x y z
|
|---|