How to do multiple conditions?

How do you test for multiple conditions?

From what I've read you can only have one condition with an if statement.

I think you need to read more. :D

Look in the Reference section of the site ( under Control Structures.

There are three commands there that will do the job. One better than the others.

Jame thank you for the pointer.

Morris - I really try but the frustration I have with ramping up on C++ in the Arduino is simply not knowing what to read because I don't know what things are called, what conflicts I'm running into, etc. Coming from an event based vb coding exposure - C++ in a continuous loop and not knowing what I don't know is a curve. I do thank everyone for the pointers to references, so that I can figure out what unknowns I don't know.

Ease up - there's a lot to learn and you won't get it all overnight. I started writing C (for a living) back about 1980 and I'm still learning. It's not like learning to tie your shoes. At the risk of detonating all the C++ folks, I'll suggest that you try starting out with fundamentals of C, and then add the additional capabilities of C++ when it seems appropriate to you.

Enjoy your reading. C (and C++) have been in use for so long, there isn’t much you can’t do with them. To quickly answer your first question:

if (a > 5 && b < 42)
  // do something

Look up && (logical “and”) and || (logical “or”).

A quick reference you might find handy:

Thank you for all the references and pointers. I’m up and running with multiple conditions if statements, now that I’m onto Boolean Operators XD. Also now that I’ve gotten some sleep and understand some of the ops. I see the point in your original reply Morris, just didn’t get it in the middle of not knowing what I didn’t know. Thanks for the Operators chart reference, more strange syntax (just joking) to figure out, by reading up on them.