Financial Management

时间限制:3000 ms  |  内存限制:65535 KB
难度:1
 
描述
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
来源
[张洁烽]原创
上传者

张洁烽

01.#include<stdio.h>
02.int main()
03.{
04.int i;
05.float a[12],sum=0;
06.for(i=0;i<12;i++)
07.{
08.scanf("%f",&a[i]);
09.sum=sum+a[i];
10.}
11.printf("%.2f",sum/12);
12.return 0;
13.}

Financial Management的更多相关文章

  1. poj 1004:Financial Management(水题,求平均数)

    Financial Management Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 126087   Accepted: ...

  2. Financial Management[POJ1004]

    Financial Management Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 179458   Accepted: ...

  3. 练习英语ing——[POJ1004]Financial Management

    [POJ1004]Financial Management 试题描述 Larry graduated this year and finally has a job. He's making a lo ...

  4. Financial Management 分类: POJ 2015-06-11 10:51 12人阅读 评论(0) 收藏

    Financial Management Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 164431   Accepted: ...

  5. Introduction to Financial Management

    Recently,i am learning some useful things about financial management by reading <Essentials of Co ...

  6. [POJ] #1004# Financial Management : 浮点数运算

    一. 题目 Financial Management Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 173910   Acc ...

  7. Financial Management POJ - 1004

    Financial Management POJ - 1004 解题思路:水题. #include <iostream> #include <cstdio> #include ...

  8. UVA 11945 Financial Management 水题

    Financial Management Time Limit: 1 Sec  Memory Limit: 256 MB 题目连接 acm.hust.edu.cn/vjudge/problem/vis ...

  9. [POJ] Financial Management

    Financial Management Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 182193   Accepted: ...

随机推荐

  1. SPOJ 7758. Growing Strings AC自动机DP

    Growing Strings 题目:给出n个字符串,问最多能够选出多少个串组成序列,并满足前一个字符串是后一个字符串的子串. 分析: AC自动机经典水题... 考虑每个节点结尾时,他能够选出最多的串 ...

  2. 4560 NOIP2015 D2T2 子串

    4560 NOIP2015 D2T2 子串  时间限制: 1 s  空间限制: 128000 KB  题目等级 : 黄金 Gold 题解  查看运行结果     题目描述 Description 有两 ...

  3. Smart法则

    设立目标不是一个很简单的事情.人们经常会犯一些基本的错误,即过于理想化.不符合客观情况.不容易执行落实,因此计划容易变成一种“美好的愿望”而已.在20世纪70年代,一位美国人为设立目标做出了一个简单而 ...

  4. C++之时间统计

    1.最精确 QueryPerformanceFrequency(&nFreq); cout <<nFreq.QuadPart<<endl;//获得计数频率 QueryP ...

  5. SQL server 2008 建立新用户

    进入Instance下的‘安全性’->登录名, 可以选择SQL server 验证,‘强制实施密码策略’.’状态‘ 为启用. 在使用的数据库下‘安全性’->登录名,选择‘登录名’,输入之前 ...

  6. HTML5+CSS3-机器猫

    <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8&quo ...

  7. Programmer's Jokes

    1.   一天, 下着小雨, 和同事们一起去上班,一位同事差点滑倒,另一位同事笑话说:如果人走路用爬的就不会摔倒了!   遂反问他:能用两行代码搞定的事情为什么要用4行呢? 2.  有趣的公式( Fr ...

  8. Part 98 Anonymous methods in c#

    What is an anonymous method? Anonymous method is a method without a name. Introduced in C# 2.0,they ...

  9. C#自定义时间显示格式

    string time = System.DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"); 下面是常见的一些日期时间显示格式 标准的For ...

  10. PHP 创建重用数据库连接函数 mysqli与PDO

    代码如下: 有兴趣的可以测试下 摘自于某书 <? php public function dbConnect( $usertype, $connectionType = 'mysqli' ) { ...