jesuashok has asked for the wisdom of the Perl Monks concerning the following question:
Hi
Please give me a Idea to sort the following array.
Result:-#!/usr/local/bin/perl my @array = ( '1-1', '2-5', '1-10', '1-3','2-1'); print "value :" , $_ , ":\n" foreach ( sort @array );
But I want to have the following Resultvalue :1-1: value :1-10: value :1-3: value :2-1: value :2-5:
But I want the result should be in sorted ordervalue :1-1: value :1-3: value :1-10: value :2-1: value :2-5:
"Keep pouring your ideas"
2005-12-18 Retitled by Arunbear, as per consideration.
Original title: 'Interpreting each and element of the array efficiently'
Back to
Seekers of Perl Wisdom