#include<stdio.h>
int main()
{
	int a,b,c,d;
	int sum1,sum2;
	scanf("%d%d%d%d",&a,&b,&c,&d);
	sum1=a*b;
	sum2=c*d;
	if(sum1!=sum2)
	{
		if(sum1>sum2)
		{
			printf("%d\n\n",sum1);
			printf("The first rectangle has an area of %d×%d=%d, and the second rectangle has an area of %d×%d=%d. Thus, the output should be %d, the larger area.",a,b,sum1,c,d,sum2,sum1);
		}
		else
		{
			printf("%d\n\n",sum2);
			printf("The first rectangle has an area of %d×%d=%d, and the second rectangle has an area of %d×%d=%d. Thus, the output should be %d, the larger area.",a,b,sum1,c,d,sum2,sum2);
		}
	}
	else
		printf("%d\n",sum1);
}