if else loop issues

SmartElectro:
Thanks guys

So basically its my boolean expression.

Thanks again

Code-wise, your syntax and structure are off in very beginner ways. I know, I started out once too.

Really, you will benefit from looking through working code on your Arduino with the Arduino site tutorial full lesson open in a browser it would be hard to not learn more than you show.

You can learn just by loading, running and going though the Arduino site tutorial, do section 05.Control.
The lessons are already there, tested and working.