Counting up-down walks to a target

A sequence starts at x0=0x_0 = 0, and each step changes the value by exactly ±1\pm 1: xixi1=1|x_i - x_{i-1}| = 1 for i=1,,10i = 1, \dots, 10. How many such sequences of 1010 steps end at x10=4x_{10} = 4?

Show hints (2)+
  1. Let uu steps be +1+1 and dd steps be 1-1. Set up u+d=10u+d=10 and ud=4u-d=4.
  2. Once u=7u=7, d=3d=3 are fixed, the sequence is just a choice of which steps are down: (103)\binom{10}{3}.

Answer

Reveal answer →

120

Want the full step-by-step worked solution? It's part of Premium - along with a worked solution for every question in the bank.

Asked at: Jane Street, SIG

Related questions