1992 | 2022-12-12 21:58:06 | tronoraa | Mágikus intervallum | python3 | Wrong answer 0/100 | 944ms | 23900 KiB |
N = input()
string = input().split(" ")
sorozat = []
for elem in string:
sorozat.append(int(elem))
lista = []
szam = []
L, R = 1, 1
sol = False
for i in range(len(sorozat)):
osszeg = 0
for j in range(i+1, len(sorozat)):
osszeg = sum(sorozat[i:j])
R, L = j, i+1
m = max(sorozat[i:j])
if m * 2 >= osszeg and len(sorozat[i:j]) > len(lista):
print(L, "", R)
Subtask | Sum | Test | Verdict | Time | Memory | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Wrong answer | 17ms | 11064 KiB | ||||
2 | Time limit exceeded | 935ms | 18396 KiB | ||||
subtask2 | 0/5 | ||||||
3 | Wrong answer | 17ms | 11540 KiB | ||||
4 | Wrong answer | 17ms | 11964 KiB | ||||
5 | Wrong answer | 17ms | 11996 KiB | ||||
6 | Wrong answer | 29ms | 12724 KiB | ||||
7 | Wrong answer | 827ms | 12912 KiB | ||||
8 | Wrong answer | 745ms | 12928 KiB | ||||
subtask3 | 0/10 | ||||||
9 | Wrong answer | 792ms | 13272 KiB | ||||
10 | Wrong answer | 794ms | 13204 KiB | ||||
11 | Wrong answer | 801ms | 13436 KiB | ||||
12 | Wrong answer | 824ms | 13644 KiB | ||||
13 | Time limit exceeded | 859ms | 5800 KiB | ||||
14 | Time limit exceeded | 875ms | 5588 KiB | ||||
subtask4 | 0/10 | ||||||
15 | Wrong answer | 17ms | 12964 KiB | ||||
16 | Wrong answer | 28ms | 13216 KiB | ||||
17 | Time limit exceeded | 869ms | 5888 KiB | ||||
18 | Time limit exceeded | 859ms | 6924 KiB | ||||
19 | Time limit exceeded | 879ms | 22264 KiB | ||||
20 | Time limit exceeded | 873ms | 23184 KiB | ||||
21 | Time limit exceeded | 873ms | 23192 KiB | ||||
subtask5 | 0/15 | ||||||
22 | Wrong answer | 17ms | 13168 KiB | ||||
23 | Time limit exceeded | 865ms | 21000 KiB | ||||
24 | Time limit exceeded | 924ms | 23412 KiB | ||||
subtask6 | 0/60 | ||||||
25 | Time limit exceeded | 865ms | 20516 KiB | ||||
26 | Time limit exceeded | 856ms | 22792 KiB | ||||
27 | Time limit exceeded | 940ms | 22608 KiB | ||||
28 | Time limit exceeded | 873ms | 21000 KiB | ||||
29 | Time limit exceeded | 944ms | 21116 KiB | ||||
30 | Time limit exceeded | 867ms | 20796 KiB | ||||
31 | Time limit exceeded | 867ms | 22908 KiB | ||||
32 | Time limit exceeded | 856ms | 23072 KiB | ||||
33 | Time limit exceeded | 860ms | 22520 KiB | ||||
34 | Time limit exceeded | 876ms | 22564 KiB | ||||
35 | Time limit exceeded | 867ms | 22404 KiB | ||||
36 | Time limit exceeded | 880ms | 22924 KiB | ||||
37 | Time limit exceeded | 888ms | 19284 KiB | ||||
38 | Time limit exceeded | 880ms | 23900 KiB | ||||
39 | Wrong answer | 749ms | 14696 KiB |