Description Farmer John made a profit last year! He would like to invest it well but wonders how much money he will make. He knows the interest rate R (an integer between 0 and 20) that is compounded annually at his bank. He has an integer amount of…
1755: [Usaco2005 qua]Bank Interest Time Limit: 5 Sec Memory Limit: 64 MBSubmit: 187 Solved: 162[Submit][Status][Discuss] Description Farmer John made a profit last year! He would like to invest it well but wonders how much money he will make. He kn…
原来强行转int可以避免四舍五入啊 #include<iostream> #include<cstdio> using namespace std; int r,y; double m; int main() { scanf("%d%lf%d",&r,&m,&y); double l=1.0+(double)r/100.0; for(int i=1;i<=y;i++) m*=l; printf("%d\n",(i…
1754: [Usaco2005 qua]Bull Math Time Limit: 5 Sec Memory Limit: 64 MBSubmit: 374 Solved: 227[Submit][Status] Description Bulls are so much better at math than the cows. They can multiply huge integers together and get perfectly precise answers ... o…
1751: [Usaco2005 qua]Lake Counting Time Limit: 5 Sec Memory Limit: 64 MB Submit: 168 Solved: 130 [Submit][Status] Description Due to recent rains, water has pooled in various places in Farmer John's field, which is represented by a rectangle of N x…
Bank Interest Time Limit : 2000/1000ms (Java/Other) Memory Limit : 131072/65536K (Java/Other) Total Submission(s) : 45 Accepted Submission(s) : 18 Problem Description Farmer John made a profit last year! He would like to invest it well but wonder…
1753: [Usaco2005 qua]Who's in the Middle Time Limit: 5 Sec Memory Limit: 64 MBSubmit: 290 Solved: 242[Submit][Status][Discuss] Description FJ is surveying his herd to find the most average cow. He wants to know how much milk this 'median' cow gives…
1754: [Usaco2005 qua]Bull Math Time Limit: 5 Sec Memory Limit: 64 MBSubmit: 398 Solved: 242[Submit][Status][Discuss] Description Bulls are so much better at math than the cows. They can multiply huge integers together and get perfectly precise answ…
1751: [Usaco2005 qua]Lake Counting Time Limit: 5 Sec Memory Limit: 64 MBSubmit: 190 Solved: 150[Submit][Status][Discuss] Description Due to recent rains, water has pooled in various places in Farmer John's field, which is represented by a rectangle…