N = int(input())
ukupno = 0
for i in range(N):
P = int(input())
pot = P % 10
baza = P // 10
potencija = 1
for i in range(pot):
potencija *= baza
ukupno += potencija
print(ukupno)
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
27 ms |
3 KB |
Output is correct |
2 |
Correct |
27 ms |
3 KB |
Output is correct |
3 |
Correct |
28 ms |
3 KB |
Output is correct |
4 |
Correct |
25 ms |
3 KB |
Output is correct |
5 |
Correct |
27 ms |
3 KB |
Output is correct |
6 |
Correct |
28 ms |
3 KB |
Output is correct |
7 |
Correct |
23 ms |
3 KB |
Output is correct |
8 |
Correct |
22 ms |
3 KB |
Output is correct |
9 |
Correct |
23 ms |
3 KB |
Output is correct |
10 |
Correct |
22 ms |
3 KB |
Output is correct |