from sys import stdin
input = stdin.readline
def f():
N = int(input())
A = list(map(int,input().split()))
for i in range(N-1):
A[i+1]+=A[i]//10
while A[-1]>=10:
A.append(A[-1]//10)
print(A[-1]*10**(len(A)-1))
f()
Subtask | Sum | Test | Verdict | Time | Memory | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Accepted | 17ms | 2916 KiB | ||||
2 | Accepted | 17ms | 2916 KiB | ||||
3 | Accepted | 17ms | 2976 KiB | ||||
subtask2 | 0/25 | ||||||
4 | Accepted | 17ms | 3044 KiB | ||||
5 | Wrong answer | 17ms | 3012 KiB | ||||
6 | Wrong answer | 17ms | 2916 KiB | ||||
7 | Wrong answer | 17ms | 2980 KiB | ||||
8 | Wrong answer | 17ms | 3064 KiB | ||||
subtask3 | 0/26 | ||||||
9 | Wrong answer | 17ms | 2916 KiB | ||||
10 | Wrong answer | 17ms | 2916 KiB | ||||
11 | Wrong answer | 18ms | 2916 KiB | ||||
12 | Wrong answer | 17ms | 2872 KiB | ||||
13 | Wrong answer | 17ms | 2948 KiB | ||||
14 | Accepted | 17ms | 2960 KiB | ||||
15 | Accepted | 17ms | 2916 KiB | ||||
16 | Accepted | 17ms | 3064 KiB | ||||
subtask4 | 19/19 | ||||||
17 | Accepted | 18ms | 3172 KiB | ||||
18 | Accepted | 18ms | 3044 KiB | ||||
19 | Accepted | 18ms | 3176 KiB | ||||
20 | Accepted | 17ms | 3192 KiB | ||||
subtask5 | 0/30 | ||||||
21 | Runtime error | 89ms | 15808 KiB | ||||
22 | Runtime error | 89ms | 15876 KiB | ||||
23 | Runtime error | 93ms | 15796 KiB | ||||
24 | Runtime error | 93ms | 15788 KiB | ||||
25 | Runtime error | 92ms | 15788 KiB | ||||
26 | Runtime error | 92ms | 15856 KiB | ||||
27 | Runtime error | 67ms | 11012 KiB | ||||
28 | Accepted | 17ms | 2916 KiB |