diff --git a/python/0076-minimum-window-substring.py b/python/0076-minimum-window-substring.py index 6cd604ac6..66b2f96e0 100644 --- a/python/0076-minimum-window-substring.py +++ b/python/0076-minimum-window-substring.py @@ -10,8 +10,7 @@ def minWindow(self, s: str, t: str) -> str: have, need = 0, len(countT) res, resLen = [-1, -1], float("infinity") l = 0 - for r in range(len(s)): - c = s[r] + for r, c in enumerate(s): window[c] = 1 + window.get(c, 0) if c in countT and window[c] == countT[c]: