Can you quickly tell me if this pseudocode makes sense or not?

后端 未结 1 1391
渐次进展
渐次进展 2021-01-29 12:30

\"enter

I believe my code is now foolproof. I will write up the pseudocode now. But I do h

1条回答
  •  孤独总比滥情好
    2021-01-29 12:48

    You seem to be including mid in the following search regardless of which side is larger. The recursive calls should both exclude mid from their search space.

    Also, for the comparison to be meaningful, the two groups being compared need to be of equal size. That will require some extra odd/even logic.

    0 讨论(0)
提交回复
热议问题