Jump to content

2 variables in one conditional statement


Jaws

Recommended Posts

i have this and i want it to check if both of them are true it comes up with yes, but if only one of them are true then i want it to come up as no.

var n = 12;  var m = 12;  function myFunction()  {     if (n < 10,m != 20)  {  alert ("Yes");  }   else  {  alert ("no");  }  }  

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...