You are viewing a single comment's thread. Return to all comments →
Using python but got time out for some hard cases:
def arrayManipulation(n, queries): # Write your code here result = [0] * n for query in queries: a, b, k = query for i in range(a-1, b): result[i] += k
return max(result)
Seems like cookies are disabled on this browser, please enable them to open this website
Array Manipulation
You are viewing a single comment's thread. Return to all comments →
Using python but got time out for some hard cases: