Skip to content

Counting climbs of n steps in strides of one or two

Question

Someone walks up a staircase of nn steps, and each stride covers either one step or two steps. How many different stride sequences take them from the bottom to exactly the top?

Short answer

Fn+1F_{n+1}, the (n+1)(n+1)-th Fibonacci number (with F1=F2=1F_1=F_2=1). The last stride starts from step n−1n-1 or step n−2n-2, so the count ana_n satisfies an=an−1+an−2a_n=a_{n-1}+a_{n-2} with a1=1a_1=1, a2=2a_2=2, giving 1,2,3,5,8,…1,2,3,5,8,\dots

Adapted from Zhou, A Practical Guide to Quantitative Finance Interviews, sec. 4.2 Combinatorial Analysis, 'Hopping rabbit', p.65; question and answer rewritten by SelfMadeQuant.com.

See the hint and the full worked solution in the question bank (free account).

Open the worked solution

Lessons behind this question