def construct_sequence(n): if n == 3: return [21, 24, 144] elif n == 4: return [21, 24, 144, 144 * 24] else: # For larger n, we can extend the pattern # but this is a simplified example seq = [21, 24, 144] prev = 144 for i in range(3, n): next_term = prev * 24 # Multiply by the last known GCD seq.append(next_term) prev = next_term return seq n = int(input()) sequence = construct_sequence(n) print(' '.join(map(str, sequence)))