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 1304. Parallelepiped

1304
Posted by vnikulin 26 Oct 2005 23:05
 Hello!
 In the description of the input data written:
 The number n is written without a decimal point. All other numbers are written with not more than two digits after a decimal point (if a number is integer a decimal point may be omitted). All the input numbers are non-negative not greater than 1000.
 But in the tests (for example, test N7) there are number with more then 2 digits after a decimal point. Please, make the tests correct, or change the problem description.
Re: 1304
Posted by Vladimir Yakovlev (USU) 27 Oct 2005 11:05
Why do you think so?

Tests are correct. All numbers have no more than two digits after a decimal point.
Re: 1304
Posted by vnikulin 27 Oct 2005 17:02
I wrote code like this (in reading data):

 scanf( "%lf", &x );
 if( fabs( int(x*100)-x*100 )>1e-2 )
  throw 0;

and my program have been crashed.
Try this (+)
Posted by Vladimir Yakovlev (USU) 29 Oct 2005 00:51
double x = 4.02;
printf("%.2lf %.2lf\n", x, int(x*100)-x*100);