n = int(input("Type a nonnegative integer: "))

while n > 0:
    print(n % 2)
    n = n // 2

