【杭电ACM】1.2.4 Financial Management

【杭电ACM】1.2.4 Financial Management

http://acm.hdu.edu.cn/game/entry/problem/show.php?chapterid=1&sectionid=2&problemid=7
 1 #include <iostream>
 2 using namespace std;
 3 
 4 int main(){
 5     double a[12];
 6     double count = 0;
 7     for(int i = 0; i < 12; i ++){
 8         cin >> a[i];
 9         count += a[i];
10     }
11     cout << '$' << count / 12 <<endl;
12     return 0;
13 }

 

posted on 2013-04-16 20:08  P,Z  阅读(221)  评论(0编辑  收藏  举报