title: Fortran string comparison with .LT
body: <p>I have to fix a bug in a very old and large financial system that uses Fortran, C and C++. I am primarily a C++ guy, have no idea abt Fortran! I have a problem understanding a Fortran statement which i think has caused a nasty bug in our systems....</p>
  
  <pre><code>if (instructions .lt. ' ')  then
      instructions = ' '
  endif
  </code></pre>
  
  <p><code>instructions</code> is a text/string.</p>
  
  <p>How does the above code behave, does it compare only the first character (atleast my tests suggest)? Basically this is a production issue, I am trying to give a workaround to my clients. A correct Fortran code to compare strings filed would also do...</p>
  
  <p>Thanks in advance</p>