One of these scripts has a loop like this:

for my $line (@lines){
 my $line2 = $line;
 $line =~ s/(\S+)\s+(\S+)\s+(\S+)/X$1 Y$2/;
 print FILEOUT $line;
 $line2 =~ s/(\S+)\s+(\S+)\s+(\S+)/Z[$3+DPad]/;
 print FILEOUT $line2;
 print FILEOUT "M98PDRILL.SUBL1\n";
 print FILEOUT "G90\n";
 print FILEOUT "G00 Z[CPlane]\n"
}

What would be a wise way of trapping a condition such as the line read and 
passed into the loop is not 3 sets of numbers and if so, skip?

Thanks guys!
jlc



--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to