Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
open (FILEHANDLE, "+<$dir/$header_file") or die "Couldn't open $dir/$h +eader_file \n"; while (<FILEHANDLE>) { $_ =~ s|solver_version_major_h.*|solver_version_major_h= $nums[0],|; $_ =~ s|solver_version_minor_h.*|solver_version_minor_h= $nums[1],|; $_ =~ s|solver_version_fix_h.*|solver_version_fix_h= $nums[2],|; print FILEHANDLE "$_"; } close FILEHANDLE;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Use $^I (was Re: updating a file)
by chip (Curate) on Nov 29, 2001 at 01:49 UTC | |
by Anonymous Monk on Nov 29, 2001 at 03:15 UTC | |
|
Re: updating a file
by IlyaM (Parson) on Nov 29, 2001 at 00:03 UTC | |
|
Re: updating a file
by broquaint (Abbot) on Nov 29, 2001 at 00:20 UTC | |
|
Re: updating a file
by IraTarball (Monk) on Nov 29, 2001 at 00:21 UTC | |
|
Re: updating a file
by Fastolfe (Vicar) on Nov 29, 2001 at 09:39 UTC | |
|
Re: updating a file
by Beatnik (Parson) on Nov 29, 2001 at 16:30 UTC | |
|
Re: updating a file
by Anonymous Monk on Nov 29, 2001 at 13:54 UTC |