#3266. Nuts

0
    ID: 3266 传统题 2000ms 1024MiB 尝试: 3 已通过: 3 难度: 1 上传者: 标签>AtCoderabc204BGESP 1级枚举(单层循环)模拟

Nuts

Nuts

题目描述

There are NN trees. The ii-th tree bears AiA_i nuts. Chipmunk will harvest nuts from the trees in the following manner:

From a tree with 1010 or fewer nuts, she does not take nuts. From a tree with more than 1010 nuts, she takes all but 1010 nuts.

Find the total number of nuts Chipmunk will take from the trees.

输入格式

Input is given from Standard Input in the following format: NN A1A_1 …\ldots ANA_N

输出格式

Print the answer.

3
6 17 28
25
4
8 9 10 11
1

提示

1≤N≤10001 \leq N \leq 1000 0≤Ai≤10000 \leq A_i \leq 1000 All values in input are integers.From the three trees, Chipmunk will take 00, 77, and 1818 nuts, for a total of 2525 nuts.

标签: AtCoder|abc204B

来源

AtCoder|abc204B