Time Based Key-Value Store (LeetCode 981)
The problem Design a class with two methods: stores for at time . returns…
Tag
25 posts
The problem Design a class with two methods: stores for at time . returns…
The problem Design an array of a given , initially all zeros, that can take…
The problem Design a with two methods: turns a binary tree into a string…
The problem You are given an integer array that never changes. Build a class…
The problem Design a class that receives a stream of non-negative integers…
The problem You are given a matrix of integers that never changes. Build a class…
The problem Design a class whose method is called once per day with that day’s…
The problem Design a calendar class with one method, . Each event is the half…
The problem Design a stack class with four operations, each in O(1) time: puts…
The problem Design a class: stores . If the key already exists, the new value…
The problem Design a class that stores up to key-value pairs and supports…
The problem Design a cache with a fixed that supports, in O(1) average time…
The problem Design a class . It starts with the numbers in . Each call to adds…
The problem Design a with three operations, each in O(1) average time: : add…
The problem Design a class with three methods: stores a word. returns only…
The problem Design two functions. turns a list of strings into a single string…
The problem Design a class with two methods: adds a number from the stream…
The problem Design a system that tracks passengers on a metro network…
The problem Design a circular queue with a fixed capacity . Support: : add at…
The problem Design a simplified Twitter with four operations: : the user posts a…
The problem Design a with two methods: stores a word of lowercase letters…
The problem Implement a hash map for integer keys and values without using any…
Some interview questions don’t ask you to solve a problem — they ask you to…
Ten problems that drill the design-a-data-structure pattern from Lesson 27. Each…
Coming from an object-oriented language, your instinct is to reach for classes…