## Facebook Hacker Cup : Peg Game Problem Solution

Continuing with my earlier solution of the First Problem â€œDouble Squareâ€, here is solution and analysis for Second Problem â€œ**Peg Game**â€

### Peg Game

At the arcade, you can play a simple game where a ball is dropped into the top of the game, from a position of your choosing. There are a number of pegs that the ball will bounce off of as it drops through the game. Whenever the ball hits a peg, it will bounce to the left with probability 0.5 and to the right with probability 0.5.

Read More …