[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] Splice troubles



What about:

#!perl

open(IN, 'file.dat');
@array = <IN>;
close IN;

@array[2] = undef;

open(OUT, '>file.dat');
print OUT @array;
close OUT;

__END__

Setting an array element to undef doesn't remove it from the array, but you
won't see a trace of it in the file.

___Carl_Johan_Berglund_________________________
   Adverb Information
   carl.johan.berglund@adverb.se
   http://www.adverb.se/



***** Want to unsubscribe from this list?
***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch