Solution
class Solution {
public:
int sum(int num1, int num2) {
return num1 + num2;
}
};
Complexity
- Time Complexity: O(1).
- Space Complexity: O(1).
class Solution {
public:
int sum(int num1, int num2) {
return num1 + num2;
}
};