I knew the general shape of the answer from having seen gambler's ruin problems before, but the general [a, b] framing made me second-guess my setup.
First, clarify the random walk model: simple symmetric random walk on integers with absorbing boundaries at a and b. Then, set up a recurrence for the expected hitting time and solve it using standard techniques (e.g., martingales or difference equations). Finally, present the closed-form solution and discuss its implications.
Pro tip: Mention that the expected hitting time scales quadratically with the interval length, which is a key insight for performance analysis in algorithms like randomized search. Also, be prepared to derive the result using martingale theory, as it demonstrates deeper probabilistic understanding.
Confirm the random walk model: simple symmetric random walk on integers, starting at position x in (a, b), with absorbing boundaries at a and b. Ask if the walk is symmetric and if steps are ±1 with equal probability.
Let E(x) be the expected number of steps to hit either boundary starting from x. Then E(x) = 1 + (E(x-1) + E(x+1))/2 for a < x < b, with boundary conditions E(a) = E(b) = 0.
Recognize that the second difference of E is constant, so E is quadratic. Solve the difference equation to get E(x) = (x - a)(b - x).
Check boundary conditions and symmetry. Note that the maximum expected steps occur at the midpoint and equal ((b-a)^2)/4, showing quadratic scaling with interval length.
Mention how the result changes for biased random walks or continuous-time processes, and relate to algorithmic applications like randomized algorithms and hitting times in graphs.
AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.