This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class LRUCache(private val capacity: Int) { | |
| inner class Node( | |
| val key: Int, | |
| val value: Int, | |
| var next: Node? = null, | |
| var prev: Node? = null | |
| ) | |
| private val cache = mutableMapOf<Int, Node>() |
NewerOlder