Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
Re:极坐标与阿基米德螺线In Reply To:极坐标与阿基米德螺线 Posted by:huicpc39 at 2006-07-15 14:12:27 #include <stdio.h> #include <math.h> #define PI acos(-1) int main(){ int Speed,Angle,Dis; double Conver,Ang; double X,Y; while(scanf("%d%d%d",&Speed,&Angle,&Dis)){ if(Speed==0) break; Ang=(double)Angle; Conver=Ang/180; Conver*=PI; Conver/=sqrt(3.0); X=log((double)Dis); Y=X+Conver; X=exp(Y)-Dis; X/=Speed; if(X<=10000) printf("%d\n",(int)(0.5+X)); else printf("God help me!\n"); } return 1; } Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator