Calculates the moving-window median for the next value of the input stream.
The median of the moving window, updated to include the next value.
The next input value.