title: Python move cursor to end of .txt lines
body: <p>I need to write() text at the end of every line in  a text file. How do I point the cursor to the end of a specific line.</p>
  
  <p>Note: seek(0,2) will put me at the end of the file, but I need the end of each line.</p>
  
  <p>Appreciate the help guys - I've combined your solutions to achieve what I need:</p>
  
  <pre><code>AllLines = [ (str.rstrip('\n') + 'Val2' + "\n" ) for str in AllLines ]
  </code></pre>
  
  <p>I can then write AllLines to a new output file.</p>