Minimum Window Substring
Hard
LC #76
stringhash mapvariable windowcountingNot attempted yet
Given strings s and t, return the shortest
substring of s that contains every character of
t, including duplicates (if t has two "a"s,
the window needs at least two).
Return "" if no such substring exists. The tests are
built so the shortest answer is unique.
Example 1
Input: s = "ADOBECODEBANC", t = "ABC"
Output: "BANC"
Example 2
Input: s = "a", t = "a"
Output: "a"
Example 3
Input: s = "a", t = "aa"
Output: ""
s has only one "a".
Constraints
- 1 ≤ len(s), len(t) ≤ 10^5
- Upper- and lowercase English letters.