X = int(input()) x, y = 1, 1 if len(str(y)) == X: a = (x - 1) // 2 if a > 0: print(a, a + 1, y) exit() while True: next_x = 3 * x + 4 * y next_y = 2 * x + 3 * y x, y = next_x, next_y if len(str(y)) == X: a = (x - 1) // 2 if a > 0: print(a, a + 1, y) break