-
Notifications
You must be signed in to change notification settings - Fork 864
Open
Description
I have a problem at 11_13,
if there are three continuous 4, the output list will have two 4s.
I think, for example, j is 5 now. After removing num1 of 5th, the num2 of 6th will move to 5th. Then j++. It leads to that num2 was passed. In other words, the for loop skiped some elements.
Change it toif(...){..} else{ j++;} may be worked. It will j++ only if if-condition is false.
Metadata
Metadata
Assignees
Labels
No labels