Data Stream LeetCode Problems: All 21, With Python Solutions
Every problem in this library that LeetCode tags Data Stream — 21 in total, 14 of them with a complete Python solution, a worked example and the time and space complexity of the approach.
- 21 problems
- 6 Easy
- 9 Medium
- 6 Hard
Data Stream problems by difficulty
Problems with a complete Python solution are listed first, then by ascending problem number.
Easy (6)
| # | Problem | Difficulty | Topics |
|---|---|---|---|
| 703 | Kth Largest Element in a Stream | Easy | Tree, Design, Binary Search Tree +3 |
| 933 | Number of Recent Calls | Easy | Design, Queue, Data Stream |
| 1656 | Design an Ordered Stream | Easy | Design, Array, Hash Table +1 |
| 170 | Two Sum III - Data structure designPremium | Easy | Design, Array, Hash Table +2 |
| 346 | Moving Average from Data StreamPremium | Easy | Design, Queue, Array +1 |
| 359 | Logger Rate LimiterPremium | Easy | Design, Hash Table, Data Stream |
Medium (9)
| # | Problem | Difficulty | Topics |
|---|---|---|---|
| 901 | Online Stock Span | Medium | Stack, Design, Data Stream +1 |
| 1352 | Product of the Last K Numbers | Medium | Design, Array, Math +2 |
| 1472 | Design Browser History | Medium | Stack, Design, Array +3 |
| 1670 | Design Front Middle Back Queue | Medium | Design, Queue, Array +2 |
| 2034 | Stock Price Fluctuation | Medium | Design, Hash Table, Data Stream +2 |
| 2526 | Find Consecutive Integers from a Data Stream | Medium | Design, Queue, Hash Table +2 |
| 362 | Design Hit CounterPremium | Medium | Design, Queue, Array +2 |
| 1429 | First Unique NumberPremium | Medium | Design, Queue, Array +2 |
| 1500 | Design a File Sharing SystemPremium | Medium | Design, Hash Table, Data Stream +2 |
Hard (6)
| # | Problem | Difficulty | Topics |
|---|---|---|---|
| 295 | Find Median from Data Stream | Hard | Design, Two Pointers, Data Stream +2 |
| 352 | Data Stream as Disjoint Intervals | Hard | Union Find, Design, Hash Table +3 |
| 1032 | Stream of Characters | Hard | Design, Trie, Array +2 |
| 1825 | Finding MK Average | Hard | Design, Queue, Data Stream +2 |
| 2102 | Sequentially Ordinal Rank Tracker | Hard | Design, Data Stream, Ordered Set +1 |
| 642 | Design Search Autocomplete SystemPremium | Hard | Depth-First Search, Design, Trie +4 |
Keep exploring
All LeetCode topicsEvery tag with a page of its own, with the number of problems behind each.LeetCode patternsThe techniques themselves, with a Python template and complexity for each.Curated study listsBlind 75, NeetCode 150 and three more, grouped by pattern.Easy problemsStart here when the data structure is new rather than the problem.
Other topics
- Array1,569
- String672
- Hash Table588
- Math485
- Dynamic Programming481
- Sorting392
- Greedy346
- Depth-First Search289
- Binary Search253
- Database249
- Tree225
- Breadth-First Search223
- Matrix216
- Two Pointers201
- Bit Manipulation194
- Binary Tree174
- Heap (Priority Queue)163
- Prefix Sum157
- Stack157
- Simulation144
- Graph138
- Counting126
- Design122
- Sliding Window116
When the Data Stream problem arrives live
Stealth Interview is a desktop app for macOS and Windows. It reads the coding problem off your screen, returns a working solution with a step-by-step explanation and its time and space complexity, and transcribes what the interviewer is saying — while staying invisible to screen sharing.