A, B = sorted(map(int, input().split()))
n = max(0, B - A - 1)
print(n)
if n > 0: print(*range(A + 1, B), end=' ')
A, B = sorted(map(int, input().split()))
n = max(0, B - A - 1)
print(n, *(range(A + 1, B)) if n else [])
A, B = sorted(map(int, input().split()))
n = max(0, B - A - 1)
print(n, *range(A + 1, B)) if n > 0 else print(n)