MathDB
2020 PUMaC Team 2

Source:

January 1, 2022
combinatorics

Problem Statement

Gary is baking cakes, one at a time. However, Gary’s not been having much success, and each failed cake will cause him to slowly lose his patience, until eventually he gives up. Initially, a failed cake has a probability of 00 of making him give up. Each cake has a 1/21/2 of turning out well, with each cake independent of every other cake. If two consecutive cakes turn out well, the probability resets to 00 immediately after the second cake. On the other hand, if the cake fails, assuming that he doesn’t give up at this cake, his probability of breaking on the next failed cake goes from p to p+0.5p + 0.5. If the expected number of successful cakes Gary will bake until he gives up isp/q p/q, for relatively prime p,qp, q, find p+qp + q.