Run time error in 2/3 test cases
@sufia.aleena12,
That’s because you are accessing a NULL pointer on line 80 or 89.
Please use this test case to dry run.
Input
5
0 9
1 1 1 5
0 10
1 2 2 4
1 1 2 8
Well apparently the issue was that i wasn’t incrementing the index after every insertion. Anyways thanks!