Back to DSA sheet
Minimum Window Substring
HardSliding WindowReturn the smallest substring of s that contains all characters of t (including duplicates), or an empty string if none exists.
Constraints
- 1 <= s.length, t.length <= 10^5
- s and t consist of letters
Sheets
Blind 75Grind 75NeetCode 150NeetCode 250
minimum-window-substring.cpp
Loading editor
Custom input (stdin)
Output
Run your code to see its output.