title: Compare two files and print only the unmatched values UNIX
body: <p>I have two files suppose 1st.dat</p>
  
  <pre><code>a
  b
  c
  d
  </code></pre>
  
  <p>and another file sppose 2nd.dat</p>
  
  <pre><code>d
  e
  f
  g
  </code></pre>
  
  <p>my output should be like </p>
  
  <pre><code>a
  b
  c
  e
  f
  g
  </code></pre>
  
  <p>I have tried using diff and sdiff but I am not getting the output as I mentioned. Please Help</p>