title: If condition to check if two strings stored in a variable occur one after other in a file
body: <blockquote>
    <p>$cat list</p>
  </blockquote>
  
  <pre><code>Hi
  welcome
  one
  two 
  good evening
  
  Value1="two"
  value2="evening"
  </code></pre>
  
  <p>For above file values, output should be echo "values are present one after the other line"</p>
  
  <p>Need to know the if condition command to check if both variable values occur one after the other in a file.</p>
  
  <p>If both variable values occur one line after other in a file, then echo some statement.</p>
  
  <p>for example:
  $cat list
      Hi
      two
      one
      three 
      good evening</p>
  
  <p>in above condition, both variable value are not present one after the other line so output should be echo "values are not present one after the other line"</p>