Insert Delete GetRandom O(1) | Leetcode 380 | Live coding session 🔥🔥🔥

preview_player
Показать описание
Here is the solution to "Insert Delete GetRandom O(1)" leetcode question. Hope you have a great time going through it.

1) 0:00 Explaining the problem out loud
2) 1:10 Algorithm walkthrough
3) 2:00 Solution
5) 12:00 Coding

For discussion/feedback

PS : Please increase the speed to 1.25X
Рекомендации по теме
Комментарии
Автор

Thanks Suchit Sir for this video.
There are two things that we can improve in this code.
1 - No need to add new Integer(val) as java automatically upcast int to Integer.
2- No need to check if (val==lastVal) because while inserting we are checking that already that no duplicates are added.

jatinthakwani
Автор

Thanks a lot for detailed and animated explanation!

ChandraShekhar-bycd
Автор

Thank you very much we will not miss this question if asked in the

aashwin.tripathi
Автор

Sir quality of video is only 360 p please change

focusman
join shbcf.ru