title: How can I check if given int exists in array?
body: <p>For example, I have this array:</p>
  
  <pre><code>int myArray[] = { 3, 6, 8, 33 };
  </code></pre>
  
  <p>How to check if given variable x is in it?</p>
  
  <p>Do I have to write my own function and loop the array, or is there in modern c++ equivalent to <code>in_array</code> in PHP?</p>