100 #ABC204B. [ABC204B] Nuts

[ABC204B] Nuts

Score : 200200 points

Problem Statement

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.

Constraints

  • 1N10001 \leq N \leq 1000
  • 0Ai10000 \leq A_i \leq 1000
  • All values in input are integers.

Input

Input is given from Standard Input in the following format:

NN

A1A_1 \ldots ANA_N

Output

Print the answer.

3
6 17 28
25

From the three trees, Chipmunk will take 00, 77, and 1818 nuts, for a total of 2525 nuts.

4
8 9 10 11
1