164932025-05-03 18:32:05algoproFasor (40)pypy3Runtime error 20/40298ms64000 KiB
# UUID: 7e68b0da-c846-477f-9185-71659674cfdf
n,k=[int(x) for x in input().split()]
h=[int(x) for x in input().split()]
j=-12
for i in range(n):
    if h[i]==max(h[max(i-k,0):min(i+k+1,n)]):
        j=i+1
        break
print(j)
SubtaskSumTestVerdictTimeMemory
base20/40
1Accepted0/039ms19432 KiB
2Accepted0/054ms21448 KiB
3Accepted2/243ms19420 KiB
4Accepted2/239ms19412 KiB
5Accepted2/245ms19428 KiB
6Accepted2/239ms19400 KiB
7Accepted2/243ms19692 KiB
8Accepted2/248ms21484 KiB
9Accepted2/254ms21376 KiB
10Accepted2/257ms21480 KiB
11Accepted2/248ms21464 KiB
12Accepted2/246ms21576 KiB
13Runtime error0/2100ms64000 KiB
14Runtime error0/2115ms64000 KiB
15Runtime error0/2108ms64000 KiB
16Runtime error0/2123ms64000 KiB
17Runtime error0/2108ms64000 KiB
18Runtime error0/2105ms64000 KiB
19Time limit exceeded0/2298ms64000 KiB
20Runtime error0/2111ms64000 KiB
21Runtime error0/2125ms64000 KiB
22Runtime error0/2107ms64000 KiB