ENG  RUS Timus Online Judge
Online Judge
Problems
Authors
Online contests
Site news
Webboard
Problem set
Submit solution
Judge status
Guide
Register
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

## Discussion of Problem 1300. Taxes

Some questions
Posted by Scythe (Berinde Radu) 10 Aug 2004 02:22
I do not understand how the rounding occurs.
First of all is it a floor(x*100)/100 (trunc-like) or a floor(x*100+0.5)/100 (round-like)?
When does it occur? At any operation other than addition?
For example, when computing the taxes for some value, the result is rounded at every segment (where percentage is applied) or only after the summation? When computing T(R*L%), R*L% is rounded before computations or not?
The gross profit for each enterprise (the one we have to compute) is also with only 2 decimals?
Re: Some questions
Posted by Vladimir Yakovlev (USU) 10 Aug 2004 12:17
Rounding is floor(x*100+0.5)/100
It applies to result of T(K) and to regional coefficient.
Thank you. You are completely right (-)
Posted by Scythe (Berinde Radu) 10 Aug 2004 12:57