Ezvor

2254. Design Video Sharing Platform

HardHash Table Preparing judge… LeetCode
Hash TableDesignHeap (Priority Queue)

Hints

Hint 1
How can we keep track of the videoId’s of removed videos?
Hint 2
When you remove a video, keep track of its videoId in an array called usedId. When a new video is uploaded, first check if usedId contains any elements, if it does, use the smallest value in usedId.