|
|
вернуться в форумTime limit exceeded on test 20 on python Послано Malve 12 мар 2022 13:49 Can you suggest what is causing this error. N = int(input()) s = [0] for i in range(N): k = int(input()) s.append(int(s[i] + k)) Q = int(input()) while Q: l, r = map(int, input().split()) print(s[r] - s[l-1]) Q -= 1 |
|
|