# PROBLEM LINK:

Contest Division 1

Contest Division 2

Contest Division 3

Contest Division 4

**Setter:** jeevanjyot

**Testers:** iceknight1093, tabr

**Editorialist:** kiran8268

# DIFFICULTY:

284

# PREREQUISITES:

None

# PROBLEM:

Chef scored X and Y marks in an examination in the first attempt and the second attempt respectively. As per the rule, the final score will be the best of the two attempts.

What is the Chef’s final score?

# EXPLANATION:

This is an implementation problem. The objective is just to check your ability to accept inputs and print an output. We just need to compare the values of X and Y and output the maximum value as Chef’s final score.

# TIME COMPLEXITY:

Time complexity is O(N).

# SOLUTION:

## Editorialist's Solution

```
int t;
cin>>t;
while(t--)
{
int x,y;
cin>>x>>y;
if(x>y)
cout<<x<<"\n";
else
cout<<y<<"\n";
}
return 0;
}
```