k, x = list(map(int, input().split()))

a = []

for i in range(x, x + k):

    if i not in a:

        a.append(i)

for i in range(x, x - k, -1):

    if i not in a:

        a.append(i)

a.sort()

print((*a))

k, x = list(map(int, input().split()))

a = []

for i in range(x, x + k):

    a.append(i)

for i in range(x - 1, x - k, -1):

    a.append(i)

a.sort()

print((*a))

k, x = list(map(int, input().split()))
a = []
for i in range(x, x + k):
    if i not in a:
        a.append(i)
for i in range(x, x - k, -1):
    if i not in a:
        a.append(i)
a.sort()
print((*a))

k, x = list(map(int, input().split()))
a = []
for i in range(x, x + k):
    a.append(i)
for i in range(x - 1, x - k, -1):
    a.append(i)
a.sort()
print((*a))

-    if i not in a: -        a.append(i) -for i in range(x, x - k, -1): -    if i not in a: -        a.append(i) +    a.append(i) +for i in range(x - 1, x - k, -1): +    a.append(i)