ezequielc / chromey-calculator

Automatically exported from code.google.com/p/chromey-calculator
1 stars 0 forks source link

Precedence of power operator is wrong #211

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
Combine the operation symbols for power and division in one expression. 

What is the expected output?
Powers should be performed first, then division (unless explicit parentheses 
are used).

What do you see instead?
The operations are performed from left to right.

What version of Chrome are you using?
 35.0.1916.153 m

What operating system are you using?
Windows 7

What country are you in?
Uruguay

Please provide any additional information below.
E.g. 2/2^2 should give 0.5
Expected: 2/2^2 -> 2/(2^2) -> 2/4 -> 0.5 (as given by google search)
Actual result: 2/2^2 -> (2/2)^2 -> 1^2 -> 1

Original issue reported on code.google.com by nicolasc...@gmail.com on 17 Jun 2014 at 1:52