[ create a new paste ] login | about

Link: http://codepad.org/q3dIkzO4    [ raw code | output | fork ]

Perl, pasted on Nov 15:
1
2
3
4
5
my $j = "12,11,10,9";
my $k = join ',' , sort {$a <=> $b} split /,/ , $j;

print $j,"\n";
print $k;


Output:
1
2
12,11,10,9
9,10,11,12


Create a new paste based on this one


Comments: