leetle

Daily challenge for 2026-09-21

629. Unoccupied Cargo Heights

A cargo rack has occupied heights listed in a strictly increasing array of integers tiers. Given integer bounds low and high, where low <= high, return how many integer heights in the inclusive range [low,high] are unoccupied. Heights outside the range do not affect the answer.

Example:
Input: tiers = [10,25,40,65], low = 24, high = 27
Output: 3
Explanation: The possible heights are 24,25,26,27. Only 25 is occupied, so 3 heights are unoccupied.

Run this challenge interactively in Python or JavaScript when the app loads.