# NYOJ 72 Financial Management

## Financial Management

Larry graduated this year and finally has a job. He's making a lot of money, but somehow never seems to have enough. Larry has decided that he needs to grab hold of his financial portfolio and solve his financing problems. The first step is to figure out what's been going on with his money. Larry has his bank account statements and wants to see how much money he has. Help Larry by writing a program to take his closing balance from each of the past twelve months and calculate his average account balance.

The input will be twelve lines. Each line will contain the closing balance of his bank account for a particular month. Each number will be positive and displayed to the penny. No dollar sign will be included.

The output will be a single number, the average (mean) of the closing balances for the twelve months. It will be rounded to the nearest penny, preceded immediately by a dollar sign, and followed by the end-of-line. There will be no other spaces or characters in the output.

100.00
489.12
12454.12
1234.10
823.05
109.20
5.27
1542.25
839.18
83.99
1295.01
1.75


1581.42

#include
int main(){
float sum,num;
for(int i=12;i>0;i--){
scanf("%f",&num);
sum+=num;
}
printf("%.2f\n",sum/12);
}

• 本文已收录于以下专栏：

## NYOJ_72 Financial Management

• think_ycx
• 2015年08月15日 13:36
• 519

## 【NYOJ】[72]Financial Management

• u011493189
• 2016年01月28日 21:55
• 113

## NYOJ 72 Financial Management

Financial Management 时间限制：3000 ms  |  内存限制：65535 KB 难度：1 描述 Larry graduated this year and ...
• qq523176585
• 2014年02月11日 11:33
• 308

## nyoj题目72:Financial Management

Financial Management 时间限制：3000 ms  |  内存限制：65535 KB 难度：1 描述 Larry graduated this year and fin...
• ojhawu
• 2015年01月11日 17:31
• 225

## ACM —— 1004 Financial Management

• WYYZ5
• 2015年09月07日 17:29
• 455

## 杭电 HDU 1064 Financial Management

Financial Management Time Limit: 400/200 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Othe...
• lsgqjh
• 2015年03月23日 20:48
• 409

## 题目72 Financial Management

• izhouxiaofei
• 2016年07月29日 12:05
• 74

## 每天一道算法_5_Financial Management

• jason0539
• 2013年10月07日 07:24
• 2338

## HDU 1064Financial Management（高精度问题）

Problem Description Larry graduated this year and finally has a job. He’s making a lot of money, bu...
• qq_32866009
• 2016年04月05日 17:03
• 251

## POJ1004-Financial Management

• lyy289065406
• 2011年07月29日 01:45
• 5763

举报原因： 您举报文章：NYOJ 72 Financial Management 色情 政治 抄袭 广告 招聘 骂人 其他 (最多只允许输入30个字)