<gh_stars>1-10
numbers = list(map(int, input().split())).sort()
numbers.sort()
print(str(numbers[0]) + ' ' + str(numbers[1]) + ' ' + str(numbers[2]))

numbers = list(map(int, input().split())).sort()
numbers.sort()
print(str(numbers[0]) + ' ' + str(numbers[1]) + ' ' + str(numbers[2]))