Or statement in design script not working

Hello,

I may be missunderstanding the design script statement “OR” but shouldnt this only return true if the input is one of these two numbers? Why is it returning true for all 4? 2 of them are zeros. What am I doing wrong here?

I would use the below syntax which is basically an “if/elif/else” statement:
image

3 Likes

An Or statement uses boolean values. It’s basically what @Jonathan.Olesen showed in an If statement. You just need to check your condition twice.
image

4 Likes

I’m no expert on this but I’m thinking the issue here is that you’re checking wheter either x equals 97 or you’re simply checking “104” without any statement. That’s my guess.
Most importantly I would like to say that you can make this work without basically doubling that bit of code. When putting them in parenthesis you can simply put or’s and numbers in there.

6 Likes