improved top-k
This commit is contained in:
parent
7386344b2e
commit
d86e3334b1
@ -36,11 +36,6 @@ class Solution:
|
||||
# Possible that we filled k elements already in this inner
|
||||
# loop, so get out
|
||||
if len(result) == k:
|
||||
break
|
||||
|
||||
if len(result) == k:
|
||||
break
|
||||
return result
|
||||
|
||||
j -= 1
|
||||
|
||||
return result
|
||||
|
Loading…
Reference in New Issue
Block a user