Problem 681 · Medium

Next Closest Time

Reuse the digits of a clock time to find the nearest later valid time, wrapping past midnight.

Open the interactive visualisation