Let's say I have an if that goes like this:
if(condition1 != asd && menu != menu1 && menu != menu2)
Can this be shortened to something like:
if(condition1 != asd && menu != (menu1 && menu2))
I tried putting parentheses around the second condition either around the two that it should not be, and around the whole thing but it does not pass the compiler.
Is it possible to shorten the second condition this way? Or is there a better way to do it?
PS. I had no idea what to call this, so feel free to edit the title.