2. Sum of Two Numbers
EasyMath~3 min
Write a function that takes two numbers, a and b, and returns their sum.
The numbers can be negative or decimal values.
Examples
Example 1
- Input:
- a = 2, b = 3
- Output:
- 5
Example 2
- Input:
- a = -4, b = 10
- Output:
- 6
- Why:
- Negative numbers work the same way.
Constraints
-1000 <= a, b <= 1000