Loading...
Pages: [1]   Go Down
Author Topic: More than one OR statement?  (Read 78 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 10
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

How do I add more than one OR statement?

I currently have;
Code:
if(dT > 0.2 || dT < -0.2) {

how do I add another OR statement to it?

I want to add x=360
Logged

East Anglia (UK)
Offline Offline
Edison Member
*
Karma: 48
Posts: 1427
May all of your blinks be without delay
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Code:
if(dT > 0.2 || dT < -0.2 || x = 360)
Logged

Johannesburg UTC+2
Offline Offline
Edison Member
*
Karma: 34
Posts: 1705
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Bzzzzzzzzzzt... shouldn't that be x == 360?
Logged

IT Crowd:
Roy... "Have you tried turning it off and on again?"
Moss.. "Have you tried forcing an unexpected reboot?"

Offline Offline
Newbie
*
Karma: 0
Posts: 10
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Ah thats where I was going wrong.  I too was only using one '=' not two

Thanks for your help  smiley
Logged

East Anglia (UK)
Offline Offline
Edison Member
*
Karma: 48
Posts: 1427
May all of your blinks be without delay
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

BONG !

Yes, of course it should.  In my defence he did say that he wanted x=360 and that is what he got !
Logged

Pages: [1]   Go Up
Print
 
Jump to: