IF inside a range - help please

Hello

I have a hopefully simple question.

I want to set up an "if" situation that applies to anything within the range of two values,
and an "else" for anything outside.

if (myValue >= lowPass BUT <= highPass)
{
do it!
} else {
don't!
}

I just dont know how to deal with the BUT (pun intended)

Thank you for any advice

fubbi

if (condition && condition)
if (lowpass <= myValue && myValue <= highPass) { doIt(); }

thanks!