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 1030. Titanic

Fokysnik What is test #3? I always get WA#3... [7] // Problem 1030. Titanic 5 Aug 2006 20:55
Maybe the problem is in acuracy...
but I use pi=2.0*acosl(0.0)...
Maybe it's printing DANGER!
but I use
if (result<99.995) printf("DANGER!\n");
Any ideas?
Fokysnik Re: What is test #3? I always get WA#3... [5] // Problem 1030. Titanic 6 Aug 2006 23:29
Sorry, I've found my mistake
:-[
DixonD (Lviv NU) Help, plz! WA3... [4] // Problem 1030. Titanic 18 Jun 2007 16:20
Did you find your mistake? What is this? I have WA3 too...
awpris Re: Help, plz! WA3... [3] // Problem 1030. Titanic 18 Jun 2007 20:22
type = extended!!!
DixonD (Lviv NU) Re: Help, plz! WA3... [2] // Problem 1030. Titanic 22 Jun 2007 02:55
I always use extended if real type is needed... Maybe test #3 is some special case?
Vedernikoff Sergey Re: Help, plz! WA3... [1] // Problem 1030. Titanic 22 Jun 2007 13:51
Distance is about 100 miles. Possibly, you make checking something like "distance < 100 then print "Dangerous!!!'".
Instead, you should check not equality of number (dist < 100), but convert it into string, and then check that length(s) < 6 (it equals to condition s < '100.00')
DixonD (Lviv NU) Re: Help, plz! WA3... // Problem 1030. Titanic 24 Jun 2007 01:25
Thanks for help! But my mistake was in other... I've got AC finally
yuzeming Re: What is test #3? I always get WA#3... // Problem 1030. Titanic 27 Nov 2009 12:37
try
const double PI=acos(-1.0);
and you will get AC