Submission #51
Details and source code
| ID | Time | User | Problem | Lang | Verdict |
|---|---|---|---|---|---|
| 51 | Jan 26, 2026, 07:05 AM | admin | RSQ Queries | py | TLE 3 |
Source Code
pyn = int(input())
a = list(map(int, input().split()))
q = int(input())
for _ in range(q):
p, L, R = map(int, input().split())
if p == 1:
a[L - 1] = R
else:
print(sum(a[L-1:R]))