sum) and the maximum sum (maxSum).start and end) to represent the sliding window.sum and the frequency map.sum and update the frequency map.sum and update the frequency map.m, update maxSum with the maximum of maxSum and sum.maxSum.