Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Help with Java

807607Oct 6 2006 — edited Oct 10 2006
I am a student in Java class. I am just learning, but have run into a math glitch (I think). I need someone to tell me if I am crazy or not! The line of code reads "Math.sqrt (7 + 18 / 7 - 23 % 10" and the answer is 2.449.
The real answer according to all calculations made on multiple calculators is 2.56.
The accual calculation is "Square Root of 7 + (18 / 7) - 3)

Thanks
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 7 2006
Added on Oct 6 2006
3 comments
111 views