Back to problems

Light Sources \U0001fa75

Algorithm · Tradedesk · Medium

Problem On an infinite one-dimensional line, a collection of luminous orbs is placed. Each orb is defined by its center coordinate and a positive radius of illumination. The data for all orbs is stored in a 2D array celestialArrangements, where the i-th orb is described by: celestialArrangements[i][0]: the integer coordinate of the orb's center. celestialArrangements[i][1]: the positive integer radius of its glow. An orb illuminates every integer point from center - radius…

Checking your access…