title: Unix command to add 2 numbers from 2 separate files and write it to a 3rd file
body: <p>I have 2 files. I need to add the count of rows of the both and write it to 3rd file.
  If the content of 3rd file is &gt;25 , i need to print error.txt and if =&lt;25 , i need to print success.txt</p>
  <p>Scenario:
  file 1(p.csv) , count: 20
  file 2 (m.csv), count : 5
  file 3 , count 25
  ---&gt;should print error.txt</p>
  <p>I have tried the below code, but file 3 is not getting generated with expected output.</p>
  <pre><code>file_1=$(cat p.csv | wc -l)
  echo $file_1
  file_2=$(cat m.csv | wc -l)
  echo $file_2
  
  file_3 = $(`expr $(file_1) + $(file_2)`)
  
  echo $file_3 &gt; file_3.txt
  
  if [ $file_3 -gt 25 ]; then
  
     touch error.txt
      
  else
  
    touch success.txt
  fi
  </code></pre>
  <p>Error message:</p>
  <pre><code>20
  5
  count_test.sh: line 16: file_1: command not found
  count_test.sh: line 16: file_2: command not found
  expr: syntax error
  count_test.sh: line 16: file_3: command not found
  count_test.sh: line 20: [: -gt: unary operator expected
  </code></pre>