n = int(input()) # Construct A a = [99, 824] a += [4353 + i for i in range(n - 2)] # Construct B b = list(range(n - 2)) # 0, 1, ..., n-3 if n > 2: b.append(n - 2) # Add next consecutive number else: # For n=3, after 0,1, we add L directly pass # Calculate L sum_a = sum(a) sum_b_initial = sum(b) L = sum_a - sum_b_initial b.append(L) # Print the result print(' '.join(map(str, a))) print(' '.join(map(str, b)))