ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1046. Geometrical Dreams

What accuracy for output? How many digits after decimal point?
Posted by Mirzayanov Michael 3 Sep 2001 05:25
Re: What accuracy for output? How many digits after decimal point?
Posted by Marat Bakirov 3 Sep 2001 17:54
The answer should be with 10^-2 accuracy.
But keep in mind that we do not accept extra zeroes.
1 != 1.0 != 1.00
1.1 != 1.10
Re: What accuracy for output? How many digits after decimal point?
Posted by Maigo Akisame (maigoakisame@yahoo.com.cn) 20 Nov 2005 04:27
But what does 'extra zeros' mean?
For example, if the accurate value is 6.0004, shall I output 6 or 6.00?
And what if 6.000000000000004, which is just floating-point error?
Re: What accuracy for output? How many digits after decimal point?
Posted by Maigo Akisame (maigoakisame@yahoo.com.cn) 21 Nov 2005 14:54
Just 6, in both cases.
Re: What accuracy for output? How many digits after decimal point?
Posted by starforever 24 Dec 2006 07:47
for C++, it would be a troublesome

cout<<setiosflags(ios::fixed)<<setprecision(2)<<result<<endl;

the program above will not work
so I have to write a void to do it myself.