2328 | 2023-01-10 15:04:27 | neszbal | Ludak Harca | python3 | Accepted 100/100 | 111ms | 36236 KiB |
N = int(input())
hely = 0
szamlalo = 0
tabla = list(map(int, input().split()))
for i in range(1, 7):
szamlalo = 0
hely = 0
while hely < N:
szamlalo += 1
hely += i
try:
while tabla[hely] != 0:
hely += tabla[hely]
except:
break
print(szamlalo, end=" ")
Subtask | Sum | Test | Verdict | Time | Memory | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Accepted | 18ms | 11072 KiB | ||||
2 | Accepted | 17ms | 11420 KiB | ||||
subtask2 | 25/25 | ||||||
3 | Accepted | 16ms | 11780 KiB | ||||
4 | Accepted | 17ms | 11792 KiB | ||||
5 | Accepted | 17ms | 11892 KiB | ||||
6 | Accepted | 26ms | 12580 KiB | ||||
7 | Accepted | 111ms | 15852 KiB | ||||
subtask3 | 40/40 | ||||||
8 | Accepted | 17ms | 12408 KiB | ||||
9 | Accepted | 17ms | 12540 KiB | ||||
10 | Accepted | 18ms | 14072 KiB | ||||
11 | Accepted | 21ms | 14936 KiB | ||||
12 | Accepted | 27ms | 18124 KiB | ||||
13 | Accepted | 34ms | 22556 KiB | ||||
14 | Accepted | 39ms | 25480 KiB | ||||
15 | Accepted | 41ms | 27304 KiB | ||||
subtask4 | 35/35 | ||||||
16 | Accepted | 29ms | 13200 KiB | ||||
17 | Accepted | 21ms | 15516 KiB | ||||
18 | Accepted | 26ms | 19180 KiB | ||||
19 | Accepted | 28ms | 21828 KiB | ||||
20 | Accepted | 28ms | 20224 KiB | ||||
21 | Accepted | 34ms | 26412 KiB | ||||
22 | Accepted | 37ms | 29496 KiB | ||||
23 | Accepted | 41ms | 31136 KiB | ||||
24 | Accepted | 39ms | 26596 KiB | ||||
25 | Accepted | 43ms | 36236 KiB |