Strange sorting, need some help

2008-07-20 Thread Tobias Eichner
I'm currently dealing with a sample program I try to understand. Here it is: --- #!/usr/bin/perl use strict; use warnings; use diagnostics; # Array to sort my @unsortiert = qw(Z A z a 19 91); # Print array to sort print "@unsortiert"; print "\n"; # Print positions of unsorted array (0 to last

Re: Strange sorting, need some help

2008-07-20 Thread Rob Dixon
Tobias Eichner wrote: > > I'm currently dealing with a sample program I try to understand. Here it is: > > --- > > #!/usr/bin/perl > > use strict; use warnings; use diagnostics; > > # Array to sort > my @unsortiert = qw(Z A z a 19 91); > > # Print array to sort > print "@unsortiert"; print "

AW: Strange sorting, need some help

2008-07-21 Thread Tobias Eichner
@rob: Thank you for your hints :-) __ Gesendet von Yahoo! Mail. Dem pfiffigeren Posteingang. http://de.overview.mail.yahoo.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://lear

Re: Strange sorting, need some help

2008-07-21 Thread Amit Saxena
On Mon, Jul 21, 2008 at 2:11 AM, Rob Dixon <[EMAIL PROTECTED]> wrote: > > Tobias Eichner wrote: > > > > I'm currently dealing with a sample program I try to understand. Here it > is: > > > > --- > > > > #!/usr/bin/perl > > > > use strict; use warnings; use diagnostics; > > > > # Array to sort > >

Re: Strange sorting, need some help

2008-07-21 Thread Gunnar Hjalmarsson
Amit Saxena wrote: On Mon, Jul 21, 2008 at 2:11 AM, Rob Dixon <[EMAIL PROTECTED]> wrote: If you were using the <=> operator to compare non-numeric strings you would get a warning, but any scalar value is a valid string so you will get no warnings if you compare numeric values with the cmp oper