2018 MOAA Team P10
Source:
January 23, 2022
combinatoricsteam2018
Problem Statement
Vincent is playing a game with Evil Bill. The game uses an infinite number of red balls, an infinite number of green balls, and a very large bag. Vincent first picks two nonnegative integers and such that , and Evil Bill places green balls and red balls in the bag, so that there is a total of balls in the bag. Vincent then picks a ball of either color and places it in the bag. Evil Bill then inspects the bag. If the ratio of green balls to total balls in the bag is ever exactly , then Evil Bill wins. If the ratio of green balls to total balls is greater than , then Vincent wins. Otherwise, Vincent and Evil Bill repeat the previous two actions (Vincent picks a ball and Evil Bill inspects the bag). If is the sum of all possible values of that Vincent could choose and be able to win, determine the largest prime factor of .