Divisor game

Let \( N \ge 2 \) be a positive integer. Alice and Bob play the following divisor game: starting with the set \( D_N \) of positive divisors of \( N\), the players take turns removing some elements from the set. At a player's turn, he or she chooses a divisor \( d \) that remains, and removes \( d \) and any of the divisors of \( d \) that remain. The player who moves last loses.

For example: \( N = 18, D_N = \{ 1,2,3,6,9,18 \} \). Alice chooses \( d=2 \), so she removes \( 1 \) and \( 2 \). The remaining set is \( \{3,6,9,18\} \). Bob chooses \( d = 9 \) and so must also remove \( 3 \). The remaining set is \( \{6,18\} \). Alice takes \( 6 \), and now Bob is forced to take \( 18 \), so he loses.

Let \( n \ge 2 \) be the largest positive integer \( \le 200 \) such that if Alice and Bob play the divisor game for \( n \) and both of them play optimally, the second player wins. Find \( n \). If no such \( n \) exists, enter \( 999 \).

×

Problem Loading...

Note Loading...

Set Loading...