Education + Jobs Hiring Website - 2025
0 like 0 dislike
1,145 views
in Online Assessments by Expert (145,340 points) | 1,145 views

1 Answer

0 like 0 dislike

image

 

For each num in the array, I used a dictonary where the values were the indicies. Then basically did a triple for loop optimized with binary search iterating through each of number's lists in the query, however this TLE-ed. Please share if you come up with an optimal solution!

by Expert (145,340 points)