Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

How is PEMDAS used?

pemdas Used
0
Posted

How is PEMDAS used?

0

One common application is in computer science. When a computer program is written, PEMDAS order is used by the computer. While the computer will follow the proper order, sometimes programmers will make mistakes. Here is a line of computer code: share = tips/workers+1 It is part of a program used to manage money at a coffee shop. What the programmer intended was, “Each worker’s share of the tips is equal to the total amount of tips divided by the number of servers working that shift (workers +1 where the plus one is for the guy at the drive-through window). His program will fail because the computer will do the division, tips/workers first (using the rule that division comes before addition) and then add 1. It might be even worse than just giving the wrong answer. If the counter is closed (and only the drive-through is open) then workers will be zero and the computer will try to divide tips by zero, an illegal operation that might crash the computer. In this example, the correct code wo

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123