def _print():
    for i in arr:
        print(i, end=' ')
    print()


arr = list(map(int, input().split()))
for i in range(len(arr) - 1):
    for j in range(len(arr) - 1):
        if arr[j] > arr[j + 1]:
            arr[j], arr[j + 1] = arr[j + 1], arr[j]
            _print()

a2d7ab3bbf494cbe3cbe90a1086d421b4006bac3
<mask token>

def _print():
    for i in arr:
        print(i, end=' ')
    print()


<mask token>

def _print():
    for i in arr:
        print(i, end=' ')
    print()


<mask token>
for i in range(len(arr) - 1):
    for j in range(len(arr) - 1):
        if arr[j] > arr[j + 1]:
            arr[j], arr[j + 1] = arr[j + 1], arr[j]
            _print()

def _print():
    for i in arr:
        print(i, end=' ')
    print()


arr = list(map(int, input().split()))
for i in range(len(arr) - 1):
    for j in range(len(arr) - 1):
        if arr[j] > arr[j + 1]:
            arr[j], arr[j + 1] = arr[j + 1], arr[j]
            _print()
