title: Scripting: Read condition written in words and converting into C - ternary operator
body: <p>I am new to the perl scripting. I am writing script to read excel file and put in text file in C programing syntax.</p>
  
  <p>So I excel sheet I have string like below:</p>
  
  <pre><code>If ((Myvalue.xyz == 1) Or (Frmae_1.signal_1 == 1)) Then a = 1
  else a = 0;
  </code></pre>
  
  <p>This I have to convert into:</p>
  
  <pre><code>a = (((Myvalue.xyz == 1) || (Frmae_1.signal_1 == 1))?1:0)
  </code></pre>
  
  <p>How this can be handled in perl?</p>