ozgurp has asked for the wisdom of the Perl Monks concerning the following question:
This is the syntax I don't understand (I now it is doing some kind of sorting but this is where the program is giving error messages):my $ct=0; my @nxxult = (); my @Ultmnsort = (); my @indexUlt = (); for(my $rn=4;$rn<=32;$rn +=4) { for(my $bn=1;$bn<=$row[0];$bn++) { $nxxult[$bn]=$ldx[$bn][$rn]; } #@indexUlt=sort{$nxxult[$a]<=>$nxxult[$b]} 0 ... $#nxxult; $Ultmnsort[$ct]=$indexUlt[0]; $Ultmxsort[$ct]=$indexUlt[$#indexUlt]; $ct++; [$#indexUlt]\n"); print TEST3 ("ct = $ct\n"); }
Here is the error message:#@indexUlt=sort{$nxxult[$a]<=>$nxxult[$b]} 0 ... $#nxxult;
Use of uninitialized value in numeric comparison (<=>) at C:\SORT.pl l +ine 791, <AREA> line 22371.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Assist in understanding old code
by tirwhan (Abbot) on Feb 28, 2005 at 23:52 UTC | |
|
Re: Assist in understanding old code
by osunderdog (Deacon) on Feb 28, 2005 at 23:13 UTC | |
|
Re: Assist in understanding of old code
by talexb (Chancellor) on Feb 28, 2005 at 22:58 UTC | |
by ozgurp (Beadle) on Feb 28, 2005 at 23:18 UTC | |
by Mugatu (Monk) on Feb 28, 2005 at 23:49 UTC |