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 1800. Murphy's Law

who know test 5,,,help!!!
Posted by Virtuoz 21 Nov 2010 18:48
here is my code
int main()
{

double l, h, w,N,angle;
double P=3.14;
double g=9.81,t,speed;
cin>>l>>h>>w;
t=sqrt(2*h/(g*100));
speed=w/60;
N=t*speed;
angle=N*360;
while(angle>360)
{
    angle=angle-1;
}
if(angle>90 && angle<270)
cout<<"bread";
else
cout<<"butter";


//system("pause");
}
Re: who know test 5,,,help!!!
Posted by Maciej Paprocki 18 Jan 2011 03:50
i think you need to remember about l in counting time te total hight should be h-0,5l because you must remember that after h-0,5l it can spin arround. and you have few more mistakes but i'm not sure of that because my one its not perfect to