滑动窗口是双指针的特殊形式

left = 0
res = float("-inf") or res = float("inf")
for right, ss in enumerate(s):
window.append(s[right])
update res
while window need shrink:
window.remove(s[left])
left += 1
update res
return res
left = 0; right = 0 
res = float("-inf") or res = float("inf")
while right < len(s):
window.append(s[right])
right += 1
update res
while window need shrink:
window.remove(s[left])
left += 1
update res
return res