simplify the bacon part in the sliding window example