 # Output problem

what does it means ?
Your answer will be considered correct if its absolute or relative error does not exceed 10^-6

it means that your answer should be correct to 6 decimal places

The statement means that if the difference between your answer and the correct answer is < (10 ^ -6), it will be considered as correct.

Eg:
Output is: 9.987654321

The output is: 9.987654321

1 Like

then what is a solution for this

difference is \le 10^{-6} or

PS :
absolute error = |your output-judge’s output|
relative error = |your output-judge’s output| /judge’s output

use double and set precision when you print output.

so why float or double give WA. And is there any possible solution for this when i am using double or float

Your logic might be incorrect or you forgot to set precision when you print it.
Which language are you using ?

i used c++ . And i used set precision also

yess might be my answer was not correct but thanks for clearing my doubt

cout.precesion(20); (try making it 30 as well) at the start of your program

Try using this
If its still WA then probably your logic is incorrect.

i think logic is incorrect because half of test cases are not getting AC