Daily challenge for 2026-06-10
526. Compact String Range Compression
Given a sorted list of unique integers, return a string representing the range compression of those numbers. Consecutive numbers should be represented as 'start-end', while individual numbers should stand alone. Ranges are formed by sequences of two or more consecutive integers. Example: Input: nums = [1, 2, 3, 5, 7, 8] Output: '1-3, 5, 7-8'
Run this challenge interactively in Python or JavaScript when the app loads.