title: if statement with multiple conditions not working using || or $$
body: <p>I am trying to make a calculator and I want it to display an error message if a mathematical sign was not included in the list was submitted.</p>
  <p>I need the <code>if</code> statement to have more that one condition and I have tried many ways and none have worked the problem is the first <code>if</code> statement</p>
  <pre><code>#include &lt;iostream&gt;
  using namespace std;
  int main()
  {
  
      string sign;
      double x;
      double y;
      string a;
      string b;
      string c;
      string d;
      string e;
      string f = &quot;addition&quot;;
      string g = &quot;subtraction&quot;;
      string h = &quot;multiplication&quot;;
      string i = &quot;division&quot;;
      a = &quot;please enter the operation type:&quot;;
      b = &quot;please enter the first number:&quot;;
      c = &quot;please enter the second number:&quot;;
      d = &quot;the answer is:&quot;;
      e = &quot;thank you for using my calculator&quot;;
  
      
      cout &lt;&lt; a &lt;&lt; endl;
      cin &gt;&gt; sign;
      cout &lt;&lt; b &lt;&lt; endl;
      cin &gt;&gt; x;
      cout &lt;&lt; c &lt;&lt; endl;
      cin &gt;&gt; y;
  
  </code></pre>
  <p>I am trying to display an error message if another operator is input by the user but nothing seems to work</p>
  <pre><code>   if (sign == f || g || h || i) {
  
          if (sign == f) {
              cout &lt;&lt; d &lt;&lt; endl;
              cout &lt;&lt; x + y &lt;&lt; endl;
  
          }
          else {
              if (sign == g) {
                  cout &lt;&lt; d &lt;&lt; endl;
                  cout &lt;&lt; x - y &lt;&lt; endl;
              }
              else {
                  if (sign == h) {
                      cout &lt;&lt; d &lt;&lt; endl;
                      cout &lt;&lt; x * y &lt;&lt; endl;
                  }
                  else {
                      if (sign == i) {
                          cout &lt;&lt; d &lt;&lt; endl;
                          cout &lt;&lt; x / y &lt;&lt; endl;
                      }
                  }
              }
          }
      }
      else {
          cout &lt;&lt; &quot;error please enter a viable option:&quot;;
      }
      
      cout &lt;&lt; e &lt;&lt; endl;
      return 0;
  
  }
  </code></pre>