def main():

    N=10

    l = list()

    for i in range(N):

        l.append(int(eval(input())))

    l.sort(reverse=True)

    for x in l[:3]:

        print(x)



if __name__=='__main__':

    main()
import sys



data = sys.stdin.readline()

l = list()

while data:

    l.append(int(data))

    data = sys.stdin.readline()



for x in sorted(l,reverse=True)[:3]:

    print(x)
def main():
    N = 10
    l = list()
    for i in range(N):
        l.append(int(eval(input())))
    l.sort(reverse=True)
    for x in l[:3]:
        print(x)


if __name__ == "__main__":
    main()

import sys

data = sys.stdin.readline()
l = list()
while data:
    l.append(int(data))
    data = sys.stdin.readline()
for x in sorted(l, reverse=True)[:3]:
    print(x)

-def main(): -    N = 10 -    l = list() -    for i in range(N): -        l.append(int(eval(input()))) -    l.sort(reverse=True) -    for x in l[:3]: -        print(x) +import sys - -if __name__ == "__main__": -    main() +data = sys.stdin.readline() +l = list() +while data: +    l.append(int(data)) +    data = sys.stdin.readline() +for x in sorted(l, reverse=True)[:3]: +    print(x)