Hi all, I need a perl program to do the following... I have a File with some values...the file has following values in different lines... device1 path1 FileName1 I need to write these values in a file in a proper place... Like in place of "Device" i need to replace it with "device1" In place of "Path" i need to replace it with "path1"...etc... Can anyone help me in writing a perl code?
Code: my @data; open(H,'yourFile.txt') or die $!; while( my $line = <H>) { push(@data,lc $line); } close H; open(H,'>yourFile.txt') or die $!; print H join("\n",@data); close H;