[Java] Leetcode 146. LRU Cache [Design #1]

preview_player
Показать описание
In this video, I'm going to show you how to solve Leetcode 146. LRU Cache which is related to Design.

In the end, you’ll have a really good understanding on how to solve Leetcode 146. LRU Cache and questions that are similar to this Design.

Now, if you want to get good at Design, please checkout my Design playlist.
Рекомендации по теме
Комментарии
Автор

Great job, clear explanation, thank you!

劉峻呈-ji
Автор

Dude that was just superb, great job.
Can you do Integer to English Words on leetcode?

AmyZahirski
Автор

There is another method of removing a node whose reference is given, copy the data from the next node and delete the next node. That way you dont even need a doubly linked list

Anna
Автор

What is the difference for implementing LRU for 4-way set associate? Is there any code for that?

maud
Автор

LOL! I did it with heaps and hashing, which is of more time complexity and takes more code for implementation.

TahliaYeseniaJones
Автор

Can you please explain LFU Cache as well? Thanks

LaytoyaThomas