Relational Operators

You are given two integers a and b. Using relational operators, determine which number is greater.

Return the following:

  • "First" if a > b
  • "Second" if b > a
  • "Equal" if a == b

Example 1:

Input: a = 5, b = 2

Output: First

Explanation: a is greater than b

Example 2:

Input: a = 1, b = 4

Output: Second

Explanation: b is greater than a

Now Your Turn!

Pick the correct output for the given input

Input: a = 10, b = 10

Still unsure what the problem is asking ?

Let’s go through a few more examples, step by step, to make it clearer.

Constraints:

  • -100 ≤ a, b ≤ 100
0
class Solution{
public:
string compareNumbers(int a, int b){
}
};
Test Case

Input:

A
B