Financial Management

Problem Description
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.
 
Input
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.
 
Output
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.
 
Sample Input
100.00
489.12
12454.12
1234.10
823.05
109.20
5.27
1542.25
839.18
83.99
1295.01
1.75
  
Sample Output
$1581.42
 #include<stdio.h>
int main()
{
double a[],b=;
int i;
for(i=;i<;i++)
{
scanf("%lf",&a[i]);
b+=a[i];
}
b/=;
printf("$%.2lf\n",b);
return ;
}

Financial Management--hdu1064的更多相关文章

  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

    Financial Management 时间限制:3000 ms  |  内存限制:65535 KB 难度:1   描述 Larry graduated this year and finally ...

  8. Financial Management POJ - 1004

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

  9. UVA 11945 Financial Management 水题

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

  10. [POJ] Financial Management

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

随机推荐

  1. 树上战争(HDU 2545 并查集求解点到根节点长度)

    树上战争 Time Limit: 10000/4000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submi ...

  2. MVC 过滤

    我们来看两个接口: public interface IActionFilter { // Methods void OnActionExecuted(ActionExecutedContext fi ...

  3. php文件处理

    1. 将数据写入文件步骤 1. 打开这个文件,如果不存在,则新建文件 2. 将数据写入文件 3. 关闭文件 2. 从文件中读取数据步骤 1. 打开一个文件,如果不能打开,如文件不存在,应安全退出 2. ...

  4. Linux下MySQL 5.6的修改字符集编码为UTF8(彻底解决中文乱码问题)

    一.登录MySQL查看用SHOW VARIABLES LIKE ‘character%’;下字符集,显示如下:+--------------------------+----------------- ...

  5. mongodb batchInsert

    看到<MongoDB 权威指南>第二版P30提到了一个batchInset的插入方法,对于一次性插入大量数据时可以提高性能.按照书上的列子,却提示错误: 本书是基于MongoDB V2.4 ...

  6. Linux合并iso

    http://blog.chinaunix.net/uid-20564848-id-74712.html http://www.yopoing.com/2008/01/windows_linux_un ...

  7. FileStream类

    使用FileStream能够对对系统上的文件进行读.写.打开.关闭等操作.并对其他与文件相关的操作系统提供句柄操作,如管道,标准输入和标准输出.读写操作可以指定为同步或异步操作.FileStream对 ...

  8. 【剑指offer】面试题20:顺时针打印矩阵

    题目描述 输入一个矩阵,按照从外向里以顺时针的顺序依次打印出每一个数字,例如,如果输入如下矩阵: 1     2  3   4 5    6   7   8 9   10 11 12 13 14 15 ...

  9. hdu 2438 Turn the corner(几何+三分)

    Problem Description Mr. West bought a new car! So he is travelling around the city. One day he comes ...

  10. UILabel Text 加下划线

    .h文件 #import <Foundation/Foundation.h> @interface CustomLabel : UILabel { BOOL _isEnabled; } @ ...