please check what is the wrong in my code
Not getting correct output
hi @shivamgoel150 there are two things wrong with your code.
-
You already declared size of v as n. If you do a push_back operation, the elements will be placed starting from the index n. You can simply access the elements from 0 -> n-1

-
Assign the first job after sorting, not before.


