How to modify lines in a file in-place?

0 votes
100 views
asked Apr 26, 2016 by Hitesh Garg (135 points)  

I want to parse a file, edit it by removing trailing spaces from every line and finally save the updated file. Is it possible to edit a line in-place while reading and updating the files?

Please log in or register to answer this question.

...