14. Maximum of Two Numbers

Given two integers a and b. Write a function int MaxOfTwo(int a, int b) that returns the maximum of them.
Example 1
Input: a = 4, b = 4
Output: 4
Explanation: The numbers are equal; you can return either one
Example 2
Input: a = 5, b = 3
Output: 5
Explanation: 5 is greater than 3
Example 3
Input: a = -1, b = 2
Output: 2
Explanation: 2 is greater than -1
easy
JavaScript
Loading...
Line 1, Char 1