# Error with OR in MacBook

**URL:** <https://discourse.processing.org/t/error-with-or-in-macbook/13717>\
**Category:** Beginners\
**Created:** [August 31, 2019, 8:53am UTC](https://discourse.processing.org/t/error-with-or-in-macbook/13717 "2019-08-31T08:53:23Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Angie](https://avatars.discourse-cdn.com/v4/letter/a/ec9cab/32.png) [@Angie](https://discourse.processing.org/u/Angie)\
**Post date:** [August 31, 2019, 8:53am UTC](https://discourse.processing.org/t/error-with-or-in-macbook/13717/1 "2019-08-31T08:53:23Z")

</div>

Good morning,  
I’m beginning using Processing and I’ve problems writing down the OR simbol. Processing gives my ERROR when I write it in my MacBook. I’m using || (alt + 1) but also I’ve tried to copy+paste directly of a good code already writed. In both cases the result is ERROR.

![OR_problems](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/2X/f/fe8b8d02993d5c757204db047691e4fe0a0960ff.jpeg)

Thank you for your time.

---

<div class="post-metadata">

**Author:** ![kll](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/kll/32/964_2.png) [@kll](https://discourse.processing.org/u/kll)\
**Post date:** [August 31, 2019, 9:56am UTC](https://discourse.processing.org/t/error-with-or-in-macbook/13717/2 "2019-08-31T09:56:33Z")

</div>

basically the logic expression must have a ( ) in a whole.

```auto
int a = 10, b = 20, x = 300;
if ( a > 5 || b < 30 ) rect (35,35,30,30);
else if ( x >= 300) circle(50,50,72); // wrong logic  
else triangle(30,70,50,30,70,70);

```

but you might use

```auto
if ( (a > 5) || (b < 30) ) { rect (35,35,30,30); }

```

---

<div class="post-metadata">

**Author:** ![Angie](https://avatars.discourse-cdn.com/v4/letter/a/ec9cab/32.png) [@Angie](https://discourse.processing.org/u/Angie)\
**Post date:** [August 31, 2019, 10:03am UTC](https://discourse.processing.org/t/error-with-or-in-macbook/13717/3 "2019-08-31T10:03:11Z")

</div>

I’ve tried and both sytems goes perfect!!!  
Thank you very much kll!!!
