stablegradients/pie-gem5-pairs huggingface dataset:
// Slower C++ solution:
#include<iostream>

#include<cstring>

#include<cstdio>

#include<cstdlib>

#include<algorithm>

using namespace std;

struct Node

{

    int key;

    Node *p,*l,*r;

};

Node *root,*NIL;

void insert(int k)

{

    Node *y=NIL;

    Node *x=root;

    Node *z;

    z=(Node*)malloc(sizeof(Node));

    z->key=k;

    z->l=NIL;

    z->r=NIL;

    while(x!=NIL)

    {

        y=x;

        if(z->key<x->key)

            x=x->l;

        else

            x=x->r;

    }

    z->p=y;

    if(y==NIL)

    {

        root=z;

    }

    else

    {

        if(z->key<y->key)

        {

            y->l=z;

        }

        else

        {

            y->r=z;

        }

    }

}

void zx(Node *u)

{

    if(u==NIL)return;

    zx(u->l);

    printf(" %d",u->key);

    zx(u->r);

}

void qx(Node *u)

{

    if(u==NIL)return;

    printf(" %d",u->key);

    qx(u->l);

    qx(u->r);



}

int main()

{

    int n,k;

    scanf("%d",&n);

    string c;

    for(int i=1;i<=n;i++)

    {

        cin>>c;

        if(c=="insert")

        {

            scanf("%d",&k);

            insert(k);

        }

        else if(c=="print")

        {

            zx(root);

            printf("\n");

            qx(root);

            printf("\n");

        }

    }

    return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.1776465166156695x):
#include<cstdio>

#include<cstring>

#include<cstdlib>

using namespace std;

#define MAXN 500000

struct node {

	int key;

	node *ch[2];

};

node tree[MAXN+5];

node *Root, *NIL, *ncnt;

void Init(){

	NIL = &tree[0];

	ncnt = &tree[1];

	Root = NIL;

}

inline node *NewNode(int val) {

	node * p = ++ncnt;

	p->key = val;

	p->ch[0] = p->ch[1] = NIL;

	return p;

}

void Insert(node * &rt, int val) {

	if(rt == NIL) {

		rt = NewNode(val);

		return ;

	}

	int d = (val >= rt->key);

	Insert(rt->ch[d], val);

}

void PreOrder(node *rt) {

	if(rt == NIL) return;

	printf(" %d", rt->key);

	PreOrder(rt->ch[0]);

	PreOrder(rt->ch[1]);

}

void InOrder(node *rt) {

	if(rt == NIL) return;

	InOrder(rt->ch[0]);

	printf(" %d", rt->key);	

	InOrder(rt->ch[1]);

}

int main() {

	int n, x;

	char op[100];

	Init();

	scanf("%d", &n);

	for(int i=0; i<n; i++){

		scanf("%s", op);

		if(op[0] == 'i') {

			scanf("%d", &x);

			Insert(Root, x);

		}

		else {

			InOrder(Root);

			puts("");

			PreOrder(Root);

			puts("");			

		}

	}

	return 0;

}
// Slower C++ solution:
#include<cstdio>

#include<cstdlib>

#include<string>

#include<iostream>

using namespace std;

struct Node

{

    int key;

    Node *right, *left, *parent;

};

Node *root, *NIL;

void insert(int k)

{

    Node *y=NIL;

    Node *x=root;

    Node *z;

    z=(Node*)malloc(sizeof(Node));

    z->key=k;

    z->left=NIL;

    z->right=NIL;

    while(x!=NIL)

    {

        y=x;

        if(z->key<x->key)

        {

            x=x->left;

        }else

        {

            x=x->right;

        }

    }

    z->parent=y;

    if(y==NIL)

    {

        root=z;

    }

    else

    {

        if(z->key<y->key)

        {

            y->left=z;

        }

        else

        {

            y->right=z;

        }

    }

}

void inorder(Node *u)

{

    if(u==NIL) return;

    inorder(u->left);

    printf(" %d",u->key);

    inorder(u->right);

}

void preorder(Node *u)

{

    if(u==NIL) return;

    printf(" %d",u->key);

    preorder(u->left);

    preorder(u->right);

}

int main()

{

    int n,i,x;

    string com;

    scanf("%d",&n);

    for(i=0;i<n;i++)

    {

        cin>>com;

        if(com=="insert")

        {

            scanf("%d",&x);

            insert(x);

        }

        else if(com=="print")

        {

            inorder(root);

            printf("\n");

            preorder(root);

            printf("\n");

        }

    }

    return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.176861185431541x):
#include<cstdio>

#include<cstring>

#include<cstdlib>

using namespace std;

#define MAXN 500000

struct node {

	int key;

	node *ch[2];

};

node tree[MAXN+5];

node *Root, *NIL, *ncnt;

void Init(){

	NIL = &tree[0];

	ncnt = &tree[1];

	Root = NIL;

}

inline node *NewNode(int val) {

	node * p = ++ncnt;

	p->key = val;

	p->ch[0] = p->ch[1] = NIL;

	return p;

}

void Insert(node * &rt, int val) {

	if(rt == NIL) {

		rt = NewNode(val);

		return ;

	}

	int d = (val >= rt->key);

	Insert(rt->ch[d], val);

}

void PreOrder(node *rt) {

	if(rt == NIL) return;

	printf(" %d", rt->key);

	PreOrder(rt->ch[0]);

	PreOrder(rt->ch[1]);

}

void InOrder(node *rt) {

	if(rt == NIL) return;

	InOrder(rt->ch[0]);

	printf(" %d", rt->key);	

	InOrder(rt->ch[1]);

}

int main() {

	int n, x;

	char op[100];

	Init();

	scanf("%d", &n);

	for(int i=0; i<n; i++){

		scanf("%s", op);

		if(op[0] == 'i') {

			scanf("%d", &x);

			Insert(Root, x);

		}

		else {

			InOrder(Root);

			puts("");

			PreOrder(Root);

			puts("");			

		}

	}

	return 0;

}
// Slower C++ solution:
#include<cstdio>

#include<iostream>

#include<cstdlib>

#include<cstring>

#include<string>

using namespace std;



struct Node{

	int key;

	Node *parent,*left,*right;

};

Node *root,*NIL;



void insert(int k)

{

	Node *y=NIL;

	Node *x=root;

	Node *z;

	z=(Node *)malloc(sizeof(Node));

	z->key=k;

	z->left=NIL;

	z->right=NIL;

	

	while(x!=NIL)

	{

		y=x;

		if(z->key < x->key)

			x=x->left;

		else

			x=x->right;

	}

	

	z->parent=y;

	if(y==NIL)

	{

		root=z;

	}

	else{

		if(z->key < y->key)

		{

			y->left = z;

		}

		else

		{

			y->right = z;

		}

	}

}



void inorder(Node *u)

{

	if(u==NIL) return;

	inorder(u->left);

	printf(" %d",u->key);

	inorder(u->right);

}



void preorder(Node *u)

{

	if(u==NIL) return;

	printf(" %d",u->key);

	preorder(u->left);

	preorder(u->right);

}



int main()

{

	int n,i,x;

	string com;

	scanf("%d",&n);

	for(int i=0;i<n;i++)

	{

		cin>>com;

	/*	if(com[0]=='f')

		{

			scanf("%d",&x);

			find(root,x);

		}*/

		if(com=="insert")

		{

			scanf("%d",&x);

			insert(x);

		}

		else if(com=="print")

		{

			inorder(root);

			printf("\n");

			preorder(root);

			printf("\n");

		}

	} 

	return 0;	

} 

// Faster C++ solution for the same problem (measured speedup: 5.176868931140826x):
#include<cstdio>

#include<cstring>

#include<cstdlib>

using namespace std;

#define MAXN 500000

struct node {

	int key;

	node *ch[2];

};

node tree[MAXN+5];

node *Root, *NIL, *ncnt;

void Init(){

	NIL = &tree[0];

	ncnt = &tree[1];

	Root = NIL;

}

inline node *NewNode(int val) {

	node * p = ++ncnt;

	p->key = val;

	p->ch[0] = p->ch[1] = NIL;

	return p;

}

void Insert(node * &rt, int val) {

	if(rt == NIL) {

		rt = NewNode(val);

		return ;

	}

	int d = (val >= rt->key);

	Insert(rt->ch[d], val);

}

void PreOrder(node *rt) {

	if(rt == NIL) return;

	printf(" %d", rt->key);

	PreOrder(rt->ch[0]);

	PreOrder(rt->ch[1]);

}

void InOrder(node *rt) {

	if(rt == NIL) return;

	InOrder(rt->ch[0]);

	printf(" %d", rt->key);	

	InOrder(rt->ch[1]);

}

int main() {

	int n, x;

	char op[100];

	Init();

	scanf("%d", &n);

	for(int i=0; i<n; i++){

		scanf("%s", op);

		if(op[0] == 'i') {

			scanf("%d", &x);

			Insert(Root, x);

		}

		else {

			InOrder(Root);

			puts("");

			PreOrder(Root);

			puts("");			

		}

	}

	return 0;

}
// Slower C++ solution:
#define _CRT_SECURE_NO_WARNINGS

#include <iostream>  

#include <stdlib.h> 

#include <stdio.h>  

#include <string>

#include <string.h>

#include <math.h>  

#include <time.h>

#include <list>

#include <map>  

#include <queue>  

#include <set>

#include <stack>

#include <vector>  

#include <algorithm>

#define ms(a) memset(a,0,sizeof(a)) 

#define inf 0x3f3f3f3f

#define MAX 100010

#define MX 10010

#define ll long long

using namespace std;

struct node

{

	int data;

	node *lch,*rch,*par;

}*root,*null;

void insert(int k)

{

	node *cur=root,*res=null,*ins=(node*)malloc(sizeof(node));

	ins->data=k;

	ins->lch=null;

	ins->rch=null;

	while (cur!=null)

	{

		res=cur;

		if(ins->data<cur->data)cur=cur->lch;

		else cur=cur->rch;

	}

	ins->par=res;//定?父?点

	if(res==null)root=ins;//第一次插入

	else{//定?左右子

		if(ins->data<res->data)res->lch=ins;

		else res->rch=ins;

	}

}

void inorder(node *cur)

{

	if(cur==null)return;

	inorder(cur->lch);

	printf(" %d",cur->data);

	inorder(cur->rch);

}

void preorder(node *cur)

{

	if(cur==null)return;

	printf(" %d",cur->data);

	preorder(cur->lch);

	preorder(cur->rch);

}

int main()

{

	int n,m;

	char oper[10];

	scanf("%d",&n);

	for (int i = 0; i < n; i++)

	{

		scanf("%s",&oper);

		if(oper[0]=='i'){

			scanf("%d",&m);

			insert(m);

		}

		else if(oper[0]=='p'){

			inorder(root);

			printf("\n");

			preorder(root);

			printf("\n");

		}

	}

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.063188477544275x):
#include<cstdio>

#include<cstring>

#include<cstdlib>

using namespace std;

#define MAXN 500000

struct node {

	int key;

	node *ch[2];

};

node tree[MAXN+5];

node *Root, *NIL, *ncnt;

void Init(){

	NIL = &tree[0];

	ncnt = &tree[1];

	Root = NIL;

}

inline node *NewNode(int val) {

	node * p = ++ncnt;

	p->key = val;

	p->ch[0] = p->ch[1] = NIL;

	return p;

}

void Insert(node * &rt, int val) {

	if(rt == NIL) {

		rt = NewNode(val);

		return ;

	}

	int d = (val >= rt->key);

	Insert(rt->ch[d], val);

}

void PreOrder(node *rt) {

	if(rt == NIL) return;

	printf(" %d", rt->key);

	PreOrder(rt->ch[0]);

	PreOrder(rt->ch[1]);

}

void InOrder(node *rt) {

	if(rt == NIL) return;

	InOrder(rt->ch[0]);

	printf(" %d", rt->key);	

	InOrder(rt->ch[1]);

}

int main() {

	int n, x;

	char op[100];

	Init();

	scanf("%d", &n);

	for(int i=0; i<n; i++){

		scanf("%s", op);

		if(op[0] == 'i') {

			scanf("%d", &x);

			Insert(Root, x);

		}

		else {

			InOrder(Root);

			puts("");

			PreOrder(Root);

			puts("");			

		}

	}

	return 0;

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

int main()

{

int a,b,c,d;

cin>>a>>b>>c>>d;

if (a*b>c*d)

{

cout<<a*b<<"\n";

}



else

{

cout<<c*d<<"\n";

}



return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.246539936714486x):
#include <stdio.h>



using namespace std;



int main()

{

 int A=1,B=1,C=1,D=1;

 scanf ("%d%d%d%d",&A,&B,&C,&D);

  if ((A*B) == (C*D))

    printf ("%d\n",A*B);

      else if ((A*B)>(C*D))

    printf ("%d\n",A*B);

    else printf ("%d\n",C*D);

    return 0;

}
// Slower C++ solution:
#include <iostream>

using namespace std;



int main() {

	int a, b, c, d, area1, area2;

	scanf("%d %d %d %d", &a, &b, &c, &d);

	

	area1 = a * b;

	area2 = c * d;

	

	if (area2 > area1) area1 = area2;

	

	printf("%d\n", area1);

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.177335568424304x):
#include <stdio.h>



using namespace std;



int main()

{

 int A=1,B=1,C=1,D=1;

 scanf ("%d%d%d%d",&A,&B,&C,&D);

  if ((A*B) == (C*D))

    printf ("%d\n",A*B);

      else if ((A*B)>(C*D))

    printf ("%d\n",A*B);

    else printf ("%d\n",C*D);

    return 0;

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

int main()

{

int a,b,c,d;

cin>>a>>b>>c>>d;

if (a*b>c*d)

{

cout<<a*b<<"\n";

}



else

{

cout<<c*d<<"\n";

}



return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.26286525081815x):
#include<stdio.h>

int main()

{

	int a,b,c,d;

	int n,m;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	if(a*b>=c*d)

	printf("%d",a*b);

	else

	printf("%d",c*d);

	return 0;

 }
// Slower C++ solution:
#include <iostream>

using namespace std;



int main() {

	int a, b, c, d, area1, area2;

	scanf("%d %d %d %d", &a, &b, &c, &d);

	

	area1 = a * b;

	area2 = c * d;

	

	if (area2 > area1) area1 = area2;

	

	printf("%d\n", area1);

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.193445543835551x):
#include<stdio.h>

int main()

{

	int a,b,c,d;

	int n,m;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	if(a*b>=c*d)

	printf("%d",a*b);

	else

	printf("%d",c*d);

	return 0;

 }
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

int main(){

    int x,y,z,m,w,h;

    cin>>x>>y>>z>>m;

    w=x*y;

    h=z*m;

    if(w>h){

    	cout<<w;

	}if(h>=w){

		cout<<h;

		

	}

	

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.251823201638771x):
#include<stdio.h>

int main()

{

	int a,b,c,d;

	int n,m;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	if(a*b>=c*d)

	printf("%d",a*b);

	else

	printf("%d",c*d);

	return 0;

 }
// Slower C++ solution:
#include <iostream>

using namespace std;

int main(){

int a,b,x,y;

cin>>a>>b>>x>>y;

if((a*b)<=(x*y)){

    cout<<x*y<<endl;

}

else{

    cout<<a*b<<endl;

}

}


// Faster C++ solution for the same problem (measured speedup: 5.259123274831947x):
#include<stdio.h>

int main()

{

	int a,b,c,d;

	int n,m;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	if(a*b>=c*d)

	printf("%d",a*b);

	else

	printf("%d",c*d);

	return 0;

 }
// Slower C++ solution:
#include <bits/stdc++.h>

using namespace std;

int main(){

	int a=0,b=0,c=0,d=0,area1=0,area2=0;

    scanf("%d%d%d%d",&a,&b,&c,&d);

    area1=a*b;

    area2=c*d;

    if(area1>area2)

      printf("%d",area1);

    else

	printf("%d",area2);  

}

// Faster C++ solution for the same problem (measured speedup: 5.1933180992810355x):
#include<stdio.h>

int main()

{

	int a,b,c,d;

	int n,m;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	if(a*b>=c*d)

	printf("%d",a*b);

	else

	printf("%d",c*d);

	return 0;

 }
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

int main()

{

int a,b,c,d;

cin>>a>>b>>c>>d;

if (a*b>c*d)

{

cout<<a*b<<"\n";

}



else

{

cout<<c*d<<"\n";

}



return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.2493308995218015x):
#include<stdio.h>



int main(){

	

	int a,b,c,d;

	

	scanf("%d %d %d %d",&a,&b,&c,&d);

	

	if((a*b)>=(c*d)){

		

		printf("%d\n",a*b);	

	}

	

	else{

		printf("%d\n",c*d);

	}

	

	return 0;

}
// Slower C++ solution:
#include <iostream>

using namespace std;



int main() {

	int a, b, c, d, area1, area2;

	scanf("%d %d %d %d", &a, &b, &c, &d);

	

	area1 = a * b;

	area2 = c * d;

	

	if (area2 > area1) area1 = area2;

	

	printf("%d\n", area1);

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.180089717098814x):
#include<stdio.h>



int main(){

	

	int a,b,c,d;

	

	scanf("%d %d %d %d",&a,&b,&c,&d);

	

	if((a*b)>=(c*d)){

		

		printf("%d\n",a*b);	

	}

	

	else{

		printf("%d\n",c*d);

	}

	

	return 0;

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

int main(){

    int x,y,z,m,w,h;

    cin>>x>>y>>z>>m;

    w=x*y;

    h=z*m;

    if(w>h){

    	cout<<w;

	}if(h>=w){

		cout<<h;

		

	}

	

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.238317246846134x):
#include<stdio.h>



int main(){

	

	int a,b,c,d;

	

	scanf("%d %d %d %d",&a,&b,&c,&d);

	

	if((a*b)>=(c*d)){

		

		printf("%d\n",a*b);	

	}

	

	else{

		printf("%d\n",c*d);

	}

	

	return 0;

}
// Slower C++ solution:
#include <iostream>

using namespace std;

int main(){

int a,b,x,y;

cin>>a>>b>>x>>y;

if((a*b)<=(x*y)){

    cout<<x*y<<endl;

}

else{

    cout<<a*b<<endl;

}

}


// Faster C++ solution for the same problem (measured speedup: 5.245598546662x):
#include<stdio.h>



int main(){

	

	int a,b,c,d;

	

	scanf("%d %d %d %d",&a,&b,&c,&d);

	

	if((a*b)>=(c*d)){

		

		printf("%d\n",a*b);	

	}

	

	else{

		printf("%d\n",c*d);

	}

	

	return 0;

}
// Slower C++ solution:
#include <bits/stdc++.h>

using namespace std;

int main(){

	int a=0,b=0,c=0,d=0,area1=0,area2=0;

    scanf("%d%d%d%d",&a,&b,&c,&d);

    area1=a*b;

    area2=c*d;

    if(area1>area2)

      printf("%d",area1);

    else

	printf("%d",area2);  

}

// Faster C++ solution for the same problem (measured speedup: 5.179962600289602x):
#include<stdio.h>



int main(){

	

	int a,b,c,d;

	

	scanf("%d %d %d %d",&a,&b,&c,&d);

	

	if((a*b)>=(c*d)){

		

		printf("%d\n",a*b);	

	}

	

	else{

		printf("%d\n",c*d);

	}

	

	return 0;

}
// Slower C++ solution:
#include<set>

#include<map>

#include<stack>

#include<queue>

#include<deque>

#include<cmath>

#include<cstdio>

#include<cctype>

#include<string>

#include<vector>

#include<cstdlib>

#include<cstring>

#include<sstream>

#include<iostream>

#include<algorithm>

#define MAXN 100000

#define pii pair<int,int>



using namespace std;

int main()

{

	int a,b,c,d;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	printf("%d",max(a*b,c*d));

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.161020822875555x):
#include<cstdio>

#include<cstring>

#include<algorithm>

using namespace std;

int i,j,k,n,m,a,b,c,d;

int main(){

	while (scanf("%d%d%d%d",&a,&b,&c,&d)!=EOF){

		printf("%d\n",max(a*b,c*d));

	}

	return 0;

}
// Slower C++ solution:
#include<set>

#include<map>

#include<stack>

#include<queue>

#include<deque>

#include<cmath>

#include<cstdio>

#include<cctype>

#include<string>

#include<vector>

#include<cstdlib>

#include<cstring>

#include<sstream>

#include<iostream>

#include<algorithm>

#define MAXN 100000

#define pii pair<int,int>



using namespace std;

int main()

{

	int a,b,c,d;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	printf("%d",max(a*b,c*d));

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.175331445684021x):
#include<stdio.h>

int main(){

	int a,b,c,d;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	int x=a*b,y=c*d;

	printf("%d\n",x<y?y:x);

}
// Slower C++ solution:
#include<set>

#include<map>

#include<stack>

#include<queue>

#include<deque>

#include<cmath>

#include<cstdio>

#include<cctype>

#include<string>

#include<vector>

#include<cstdlib>

#include<cstring>

#include<sstream>

#include<iostream>

#include<algorithm>

#define MAXN 100000

#define pii pair<int,int>



using namespace std;

int main()

{

	int a,b,c,d;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	printf("%d",max(a*b,c*d));

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.175331445684021x):
#include<stdio.h>

#include<algorithm>

using namespace std;

int main()

{

	int a,b,c,d;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	int x=a*b;

	int y=c*d;

	printf("%d\n",max(x,y));

	return 0;

}
// Slower C++ solution:
#include <iostream>

using namespace std;

#define LL long long



int main()

{

    LL a, b, c, d;

    while(cin >> a >> b >> c >> d){

        LL x = a * b;

        LL y = c * d;

        cout << max(x, y) << '\n';

    }

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.242509451706729x):
#include<stdio.h>

#include<algorithm>

using namespace std;

int main()

{

	int a,b,c,d;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	int x=a*b;

	int y=c*d;

	printf("%d\n",max(x,y));

	return 0;

}
// Slower C++ solution:


#include<bits/stdc++.h>

typedef long long ll;

using namespace std;



int main()

{

    ll a,b,c,d;

    ll r1,r2;



    while(cin>>a>>b>>c>>d)

    {

        r1=a*b;

        r2=c*d;



        if(r1>=r2)

            cout<<r1<<endl;

        else

            cout<<r2<<endl;

    }

    return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.242653611892177x):
#include<stdio.h>

#include<algorithm>

using namespace std;

int main()

{

	int a,b,c,d;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	int x=a*b;

	int y=c*d;

	printf("%d\n",max(x,y));

	return 0;

}
// Slower C++ solution:
#include<bits/stdc++.h>



using namespace std ;



#define i64 long long int



int main()

{

    ios_base::sync_with_stdio(false);

    i64 a,b,c,d;

    cin>>a>>b>>c>>d;

    if(a*b>c*d)

    {

        cout<<a*b<<endl;

    }

    else

    {

        cout<<c*d<<endl;

    }

    return 0;



}


// Faster C++ solution for the same problem (measured speedup: 5.3070885897070905x):
#include<stdio.h>

#include<algorithm>

using namespace std;

int main()

{

	int a,b,c,d;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	int x=a*b;

	int y=c*d;

	printf("%d\n",max(x,y));

	return 0;

}
// Slower C++ solution:
#include <iostream>

using namespace std;



int main() {

	

	int A,B,C,D;

	

	cin >> A;

	cin >> B;

	cin >> C;

	cin >> D;

	

	if(A*B >= C*D){

	    printf("%d",A*B);

	}

	else{

	    printf("%d",C*D);

	}

	

	return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.220414576515936x):
#include<stdio.h>

#include<algorithm>

using namespace std;

int main()

{

	int a,b,c,d;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	int x=a*b;

	int y=c*d;

	printf("%d\n",max(x,y));

	return 0;

}
// Slower C++ solution:
#include<set>

#include<map>

#include<stack>

#include<queue>

#include<deque>

#include<cmath>

#include<cstdio>

#include<cctype>

#include<string>

#include<vector>

#include<cstdlib>

#include<cstring>

#include<sstream>

#include<iostream>

#include<algorithm>

#define MAXN 100000

#define pii pair<int,int>



using namespace std;

int main()

{

	int a,b,c,d;

	scanf("%d%d%d%d",&a,&b,&c,&d);

	printf("%d",max(a*b,c*d));

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.1648995606963695x):
#include<stdio.h>

#include<algorithm>

using namespace std;

int main()

{

	int a, b, c, d;

	while(~scanf("%d%d%d%d", &a, &b, &c, &d))

	{

		printf("%d\n", max(a * b, c * d));

	}

	return 0;

}
// Slower C++ solution:
#include <iostream>

using namespace std;

#define LL long long



int main()

{

    LL a, b, c, d;

    while(cin >> a >> b >> c >> d){

        LL x = a * b;

        LL y = c * d;

        cout << max(x, y) << '\n';

    }

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.231942156409635x):
#include<stdio.h>

#include<algorithm>

using namespace std;

int main()

{

	int a, b, c, d;

	while(~scanf("%d%d%d%d", &a, &b, &c, &d))

	{

		printf("%d\n", max(a * b, c * d));

	}

	return 0;

}
// Slower C++ solution:


#include<bits/stdc++.h>

typedef long long ll;

using namespace std;



int main()

{

    ll a,b,c,d;

    ll r1,r2;



    while(cin>>a>>b>>c>>d)

    {

        r1=a*b;

        r2=c*d;



        if(r1>=r2)

            cout<<r1<<endl;

        else

            cout<<r2<<endl;

    }

    return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.232086026012249x):
#include<stdio.h>

#include<algorithm>

using namespace std;

int main()

{

	int a, b, c, d;

	while(~scanf("%d%d%d%d", &a, &b, &c, &d))

	{

		printf("%d\n", max(a * b, c * d));

	}

	return 0;

}
// Slower C++ solution:
#include<bits/stdc++.h>



using namespace std ;



#define i64 long long int



int main()

{

    ios_base::sync_with_stdio(false);

    i64 a,b,c,d;

    cin>>a>>b>>c>>d;

    if(a*b>c*d)

    {

        cout<<a*b<<endl;

    }

    else

    {

        cout<<c*d<<endl;

    }

    return 0;



}


// Faster C++ solution for the same problem (measured speedup: 5.296391122623457x):
#include<stdio.h>

#include<algorithm>

using namespace std;

int main()

{

	int a, b, c, d;

	while(~scanf("%d%d%d%d", &a, &b, &c, &d))

	{

		printf("%d\n", max(a * b, c * d));

	}

	return 0;

}
// Slower C++ solution:
#include <iostream>

using namespace std;



int main() {

	

	int A,B,C,D;

	

	cin >> A;

	cin >> B;

	cin >> C;

	cin >> D;

	

	if(A*B >= C*D){

	    printf("%d",A*B);

	}

	else{

	    printf("%d",C*D);

	}

	

	return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.209891817728092x):
#include<stdio.h>

#include<algorithm>

using namespace std;

int main()

{

	int a, b, c, d;

	while(~scanf("%d%d%d%d", &a, &b, &c, &d))

	{

		printf("%d\n", max(a * b, c * d));

	}

	return 0;

}