0101少儿编程
Home
ProblemSet
Source/Category
Contest
Status
Ranklist
F.A.Qs
IDE下载
Login
Register
5340: 【27课】【3161】求整数的和与均值
Memory Limit:128 MB
Time Limit:1.000 S
Judge Style:Text Compare
Creator:
Submit:203
Solved:101
Submit
Submit Record
Statistics
ShowOff!
Description
读入
n
(
1
≤
n
≤
10000
)个整数,求它们的和与均值。
Input
输入第一行是一个整数
n
,表示有
n
个整数。第
2
∼
n
+
1
行每行包含
1
个整数。每个整数的绝对值均不超过
10000
。
Output
输出一行,先输出和,再输出平均值(保留到小数点后
5
位),两个数间用单个空格分隔。
Sample Input
Copy
4 344 222 343 222
Sample Output
Copy
1131 282.75000
Source/Category
一本通编程启蒙
循环结构
Submit
Submit Record
Statistics
ShowOff!