#include <stdio.h>

int main(void)
{
	int i,j,tmp;
	int mts[11] = {0};

	for(i = 0; i < 10; i++)
	{
		scanf("%d",&mts[i]);
	}

	for(j = 0; j < 10; j++)
	{
		for(i = 0; i < 10 - j; i++)
		{
			if(mts[i] < mts[i+1])
			{
				tmp = mts[i];
				mts[i] = mts[i+1];
				mts[i+1] = tmp;
			}
		}
	}

	printf("%d\n%d\n%d\n",mts[0],mts[1],mts[2]);

	return 0;

}