Search
⌘K

Leetcode 3175. Find The First Player to win K Games in a Row

Given unique skill levels in queue order, repeatedly compare the first two players, keep the higher as the current champion (loser goes to the back), and return the initial index of the first player who wins k games in a row. Note: n can be up to 1e5 and k up to 1e9, so solutions should avoid naive long simulations and exploit that the global maximum will eventually dominate.


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Comments

Your account is free and you can post anonymously if you choose.