Hi,
I have thousands of files with the following format:
0.642375 125 SIL
1.0705 125 ઔર્
1.3651875 125 આત્
1.519875 125 મ
...
...
...
7.2140627 125 સે
7.478125 125 હટ્
7.622625 125 જા
7.956125 125 ઓ
8.192375 125 SIL
8.252 125 SIL
8.464 125 SIL
8.706 125 SIL
... and so on
Also, the number of lines are not same in all the files. I just want one line with SIL at the end (shown in red) and wish to get rid of the others following it.
Can anyone help me how can I resolve this using perl?
I'd be great if i can input all the files at a time process it and save it back with required lines. I am acquainted with file handling. All I seek help for is the formatting (i.e., getting rid of those extra lines).
Thank you.
In reply to removing lines that are in the end of a file by bhargavkanakiya
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |