Let a coin with shows H and T with probabilities 1/2, 1/2 , be tossed repeatedly. Let B be the sequence HTH. We want to compute the expected time to get the sequence HTH ENB. Imagine that a gambler bets 1 dollar on the sequence B occurring to the following rules of fair odds. At the first toss, if heads appears, he receives 2 dollars (including his bet) and must parley the 2 dollars on the occurrence of Tails on next toss. In case he wins he receives 12 dollars and must partly the whole amount of 12 dollars on the occurance of heads on the next toss. If he wins, he recieves the toal amount of 2 dollars and the game is over.