AtCoder Beginner Contest 204
翻译中…
Problem Statement
翻译中…
There are $N$ trees. The $i$-th tree bears $A_i$ nuts.
翻译中…
Chipmunk will harvest nuts from the trees in the following manner:
翻译中…
- From a tree with
$10$or fewer nuts, she does not take nuts. - From a tree with more than
$10$nuts, she takes all but$10$nuts.
翻译中…
Find the total number of nuts Chipmunk will take from the trees.
翻译中…
Constraints
翻译中…
$1 \leq N \leq 1000$$0 \leq A_i \leq 1000$- All values in input are integers.
翻译中…
Input
翻译中…
Input is given from Standard Input in the following format:
翻译中…
N
A_1 \ldots A_N
翻译中…
Output
翻译中…
Print the answer.
翻译中…
样例
Input #1
3
6 17 28
Output #1
25
From the three trees, Chipmunk will take $0$, $7$, and $18$ nuts, for a total of $25$ nuts.
Input #2
4
8 9 10 11
Output #2
1
题目信息
题面与样例版权归 AtCoder 及出题人所有;中文翻译由 AI 生成(CI 管线),如有出入请以原文为准。