#t9. 符号函数计算

符号函数计算

Sign Function

Problem Description

For any integer nn, the sign function sign(n)\text{sign}(n) is defined as follows:

  • sign(n)=0\text{sign}(n) = 0 when n=0n = 0;
  • sign(n)=−1\text{sign}(n) = -1 when n<0n < 0;
  • sign(n)=1\text{sign}(n) = 1 when n>0n > 0.

Write a program to compute this function's value for any integer read in.

Input Format

A single line containing an integer nn.

Output Format

Output on one line, in the format sign(n) = value, the function value of the integer nn.

Sample Input 1

5

Sample Output 1

sign(5)=1

Sample Input 2

0

Sample Output 2

sign(0)=0

Sample Input 3

-3

Sample Output 3

sign(-3)=-1

Constraints

−231≤n≤231−1-2^{31} \le n \le 2^{31} - 1

Hint

  • The definition of sign is given in the statement; just pick one of the three cases.
  • The output format sign(5)=1 is assembled — check the parentheses, the equals sign, and the minus sign character by character against the samples.