题解 | #扭蛋机#
https://www.nowcoder.com/practice/9d26441a396242a9a0f7d2106fc130c7
def egg(n):
str_word = ''
if n == 1:
return '2'
elif n == 2:
return '3'
elif n % 2 == 1 and n != 1:
str_word = '2'
elif n % 2 == 0 and n != 2:
str_word = '3'
return str_word + egg(int((n-1)/2))
n = int(input())
print(egg(n)[::-1])
str_word = ''
if n == 1:
return '2'
elif n == 2:
return '3'
elif n % 2 == 1 and n != 1:
str_word = '2'
elif n % 2 == 0 and n != 2:
str_word = '3'
return str_word + egg(int((n-1)/2))
n = int(input())
print(egg(n)[::-1])