Problem 3768 · Hard
Count the inversions inside every window of fixed length and keep the smallest count.
Open the interactive visualisation