I am having trouble understanding the cause of getting memory limit exceeded for this problem

Правка en1, от zzzzsust19, 2022-12-09 13:55:47

This is my submission 184446767 The problem link: https://codeforces.com/problemset/problem/1620/E

At first I thought I was getting MLE for using maps, then I used vector for mapping the elements of list. Not to mention, the number of elements in which test case I am getting MLE is surprisingly small. It's only 1000 * 2 items in array at most.

Now, I created a separate vector to store queries, it's a 2d vector. I am using first dimension to store the index where the query starts. The second dimension implies the number of queries in that index. This is the only thing that looks sus to me. Otherwise I don't get the cause of MLE

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en1 Английский zzzzsust19 2022-12-09 13:55:47 747 Initial revision (published)