Leetcode 128. Longest Consecutive Sequence | Mock Interview

preview_player
Показать описание
Рекомендации по теме
Комментарии
Автор

Why it is not O(n2) as we are using nested loops ?

shivamvarshneyable
Автор

awesome content! Please keep making more such mocks it really helps! Just a doubt here in while loops for left and right lets say number is 5 then we do left-- it becomes 4 but where do we check if our set contains 4 or not? I guess it should be like while(s.count(left)).am i missing something here

shreyasingh
Автор

Why would the 2nd solution only work till 10^7?

agarwalminal
Автор

Can you please solve Merge Accounts problem on Leetcode.

gatheringknowledge
welcome to shbcf.ru