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 1192. Ball in a Dream

where is the mistake?help!
Posted by Amy 29 Jul 2003 15:14
const
g=10.00;
var
v,a:longint;
k,b,ans:extended;
begin
  readln(v,a,k);
  b:=2*sin(a/180*pi)*cos(a/180*pi)/g;
  ans:=b*v*v/(1-1/k);
  writeln(ans:0:2);
end.
Re: where is the mistake?help!
Posted by Vovka 21 Oct 2004 16:27
Use 3.1415926535 instead of pi
Re: where is the mistake?help!
Posted by John Carry 24 Oct 2008 23:40
const
g=10.00;
var
v,a:longint;
k,b,ans:extended;
begin
readln(v,a,k);
b:=2*sin(a/180*pi)*cos(a/180*pi)/g;
ans:=b*v*v/(1-1/k); =>>(1-1) What does it mean?
writeln(ans:0:2);
end.
Re: where is the mistake?help!
Posted by John Carry 25 Oct 2008 02:07
Sorry!!!
Now I understood!!!
It´s 1 - (1/k) and no (1-1)/k