Problem 1643 · Hard

Kth Smallest Instructions

Count the paths that start with H using a binomial coefficient, then choose each move by comparing k with that count.

Open the interactive visualisation