Convert positive integers to negative integers
Given a number, return the number with a negative sign.
Sample Code:
function negNum(num) {
// Enter your logic here...
}
Examples:
Input: 5
Output: -5
Explanation: The input number has been converted to a negative number.
Input: -1
Output: -1
Explanation: The input is already a negative number.