n=int(input())
a=int(input())
b=int(input())
s=int(input())
for i in range(48)
if a>b>s>n:
    print(a,b,s,n)
if b>a>s>n:
    print(b,a,s,n)
if s>a>b>n:
    print(S,a,b,n)
if n>s>a>b:
    print(n,s,a,b)

