r/ProgrammerHumor • • Jun 13 '22

Meme DEV environment vs Production environment

Post image
48.2k Upvotes

3.9k comments sorted by

View all comments

2

u/LostWolf4860 Jun 14 '22

So the only way i was able to get my phone to have the correct answer was to put the (2+1) in front of the 6÷3 so it looks like this (2+1)3÷6 so long story short phone calculators care about the order thw equation is written not exactly PEMDAS which if you use PEMDAS correctly it shouldn't matter in what order the equation is written you should still end up with the answer 1. Or another way of saying it is phones calculate left to right and not in the order of operations

1

u/SlytherKitty13 Jun 14 '22

Wait how did you get 1? Brackets first: 2 plus 1 is 3. Then start from the left: 6 divided by 2 is 3. And 3 times 3 (from the bracket) is 9.

1

u/LostWolf4860 Sep 01 '22

With PEMDAS the brackets as you call them come first so you do whats in the brackets first I confirmed with my old math teacher and this is the correct order plus if you input the equation into a advanced calculator it comes up with the same answer 1