The program needs to read an integer from the console and then output −1, 0, or 1 depending on whether the input is negative, zero, or positive, respectively.
An integer n.
The sign of the given number: −1, 0, or 1.
Example 1
Example 2
Example 3