N = int(input().strip()) print(''.join([str(n+1) * int(i) for n, i in enumerate(input().strip().split(' '))])[::-1])