10434 - Working With Specific Gravity
Posted: Wed Nov 15, 2006 7:53 am
The problem is not a big deal, but watch out that you use a good pi value.
I used 3.14159 from memory, but it was not good enough.
Pi is in math.h, and on MS compilers its ifdef'd out.
here it is: 3.14159265358979323846, u can borrow it
Maybe best to copy & paste it to a variable on such platforms as the required #define is not standard C++ & may give compile errors on the Judge.
good luck
I used 3.14159 from memory, but it was not good enough.
Pi is in math.h, and on MS compilers its ifdef'd out.
here it is: 3.14159265358979323846, u can borrow it

Maybe best to copy & paste it to a variable on such platforms as the required #define is not standard C++ & may give compile errors on the Judge.
good luck
