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 |
怪了!!!#include<iostream> using namespace std; int main() { int R,Y; double M,rate; cin>>R>>M>>Y; rate=(100+R)/100.0; while(Y--) M=M*rate; cout<<(int)M<<endl; return 0; } 这样AC了 #include<iostream> using namespace std; int main() { int R,Y; float M,rate; cin>>R>>M>>Y; rate=(100+R)/100.0; while(Y--) M=M*rate; cout<<(int)M<<endl; return 0; } 这样却WA!不解啊????????? Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator