title: how to check in if condition if the the word entered by the user is present in the array assigned to a variable
body: <p>please refer to line 2 after comment.
  this issue is mentioned in the code in comments.</p>
  <pre><code>//valid input to be taken by user
  var validanswerone = [&quot;yes&quot; , &quot;YES&quot;, &quot;Yes&quot;];//here i want to take multiple form of input the user might type but my efforts are going effort less.
  var validanswertwo = &quot;no&quot;;//only this is working.
  
  //conditions
  if (userage === validanswerone){
    console.log(&quot;\n\nPlease put your credit card details in the next page&quot; + &quot;, you will be redirected soon!&quot;);
  }
  else if(userage === validanswertwo){
    console.log(&quot;\n\nWe are sorry!&quot;);
    console.log(&quot;\n\nPlease try back in&quot; + &quot;  *days remaining to be become 18+ will be added in the coming update still not understood the formula to implicate it*&quot;);
  }
  else{
    console.log(&quot;\n\nInvalid input!&quot;)
  }
  </code></pre>