I am seeking a way to modify my current if statement, which looks like this:
if (x==a||x==b||x==c||x==d||x==e) {
alert('Hello World!')
};
Is there a method to test whether x
matches any of the values in an array such as [a,b,c,d,e]
?
Your assistance is greatly appreciated!