Question 10
Number theory BDMO 2021 Selection · Dhaka
You have a magical machine that takes a positive integer as input. If you give an even number as input to the machine, it returns one-half of it as output. If you give an odd number as input to it, it adds three to it and returns it as output. The machine does not stop there. Instead, it keeps running by using its current output as the next input. It only stops running once it outputs a number it has already received as input in the past. Let be the set of possible numbers the machine stops on. What is the sum of the elements of ?