Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do i do an if statement , where

Status
Not open for further replies.

Flanamacca

Programmer
Mar 11, 2003
3
AU
How do i do an if statement , where it checks :

If something is something or if something is something else before doing some code??

EG:
If ( x > 7) or If (y <4)
{Run this code}
 
what you do is...
if (something is true || something else is true){
do something else;
if you do it this way;
you can have lots of lines of code in here;
}
the || is the &quot;or&quot;
the && is &quot;and&quot;
of course, your < and > are standard, but then you have the
!= as &quot;is not equal to&quot;
are these binary operators what you're looking for
good luck, if you need more, just post it!
~Thani
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top