C Program to check whether the given number is positive or negative

#include<stdio.h>
int main()
{
    int number;
    printf("Enter the number\n");
    scanf("%d",&number);
    if(number>0)
        printf("%d is Positive",number);
    else if(number<0)
        printf("%d is Negative",number);
    else
        printf("%d is zero",number);
}

Output:
        
     C Program to check whether the given number is positive or negative


C Program to check whether the given number is positive or negative


C Program to check whether the given number is positive or negative



Comments