title: How do I remove lines of data in the middle of a text file with Ruby
body: <p>I know how to write to a file, and read from a file, but I don't know how to modify a file besides reading the entire file into memory, manipulating it, and rewriting the entire file. For large files this isn't very productive.</p>
  
  <p>I don't really know the difference between append and write. </p>
  
  <p>E.g.</p>
  
  <p>If I have a file containing:</p>
  
  <pre><code>Person1,will,23
  Person2,Richard,32
  Person3,Mike,44
  </code></pre>
  
  <p>How would I be able just to delete line containing Person2?</p>