import sys


def main():
    l = []
    for line in sys.stdin.readlines():
        l.append(int(line.rstrip()))

    for _ in range(3):
        print max(l)
        l.remove(max(l))

main() import sys sys def main():
    l = []
    for line in sys.stdin.readlines():
        l.append(int(line.rstrip()))

    for _ in range(3):
        print max(l)
        l.remove(max(l)) main l = [] l [] for line in sys.stdin.readlines():
        l.append(int(line.rstrip()))

     line sys.stdin.readlines() sys.stdin.readlines sys.stdin sys stdin readlines l.append(int(line.rstrip())) l.append l append int(line.rstrip()) int line.rstrip() line.rstrip line rstrip for _ in range(3):
        print max(l)
        l.remove(max(l)) _ range(3) range 3 print max(l) max l l.remove(max(l)) l.remove l remove max(l) max l main() main def main():
    l = []
    for line in sys.stdin.readlines():
        l.append(int(line.rstrip()))

    for _ in range(3):
        print max(l)
        l.remove(max(l)) def main():
    l = []
    for line in sys.stdin.readlines():
        l.append(int(line.rstrip()))

    for _ in range(3):
        print max(l)
        l.remove(max(l)) main
import sys


def main():
    l = []
    for line in sys.stdin.readlines():
        l.append(int(line.rstrip()))

    for _ in range(3):
        print max(l)
        l.remove(max(l))

main()