Find All Numbers Disappeared in an Array II
Sort the values that are present, then walk the gaps inside [lower, upper] and merge consecutive missing numbers into ranges.
Sort the values that are present, then walk the gaps inside [lower, upper] and merge consecutive missing numbers into ranges.