Ada and the Staircase

cook
off

#1

can somebody explain the question and the approach to solve this question,i cannot understand the editorial