I am working on an application where multiple sensor values need to be evaluated. Normally I would use:
if ( (acx < 100) && (acy > 100) )
{
do things;
}
Now I need to do things when acx value is either below 50 or above 150, can I nest this the following way?
if ( ((acx < 50)||(acx > 150)) && (acy > 100) )
{
do other things;
}
Or are there better ways to do this?