title: How to extract non-matching lines from two text files?
body: <p>Extracting  matching lines using perl is known to me but I want the lines from two files which are not matching i.e. they are unique to the file among two text files.</p>
  
  <p><strong>file1</strong>:</p>
  
  <pre><code>one|E2027.1|073467|66   ATGCTATGTTTTGCTAAT  
  one|E2002.1|073405|649  ATGAAAGCTTTAAAGAAA  
  one|E2001.1|734704|201  ATGTTTTCAGGTATTATA  
  one|E2025.1|073468|204  ATGAAACAGAAATATATT  
  one|E2028.1|073431|578  ATGTTATTTAATTATGGT  
  one|E2040.1|073743|862  ATGATTTATCCTAATAAT   
  </code></pre>
  
  <p>.........~2000 such lines  </p>
  
  <p><strong>file2</strong>:  </p>
  
  <pre><code>one|E2027.1|073467|66  
  one|E5005.5|000005|005  
  one|E2001.1|734704|201  
  one|E2025.1|073468|204  
  one|E2028.1|073431|578  
  one|E2040.1|073743|862    
  </code></pre>
  
  <p>.........~2000 such lines </p>
  
  <p>how to extract the lines not matching using perl or cmd commands?<br>
  here e.g. line 2 of file two is unique to file 2.....!!!</p>
  
  <p>Here's what I have so far</p>
  
  <pre><code>foreach(@2) {
      @org=split('\t',$_);
      chomp($two=$_);
      foreach(@1) {
          if($_=~m/^$two.+/) {
              print OUT1 "$_";
          } else {
              print OUT2 "$_";
          }
      }
  }
  </code></pre>
  
  <p>but else output gives GB of data.</p>