programming9
  • Flowcharts
  • Programs
      • Back
      • C Programs
      • C++ Programs
      • Java Programs
      • Python Codes
      • HTML Codes
      • Java Script Codes
      • SQL Codes
  • Tutorials
      • Back
      • Java Tutorials
      • Competitive Programming
      • Python Tutorials
      • C Programming
  • Blog
  • Login

C Program to Find Given Integer is Positive or Negative

Written by: RajaSekhar
  • basic c programs
/* www.programming9.com */
#include<stdio.h>
main()
{
    int num;
    printf("Enter a Number to test ZERO or +ve or -ve :");
    scanf("%d",&num);
    if(num==0)
        printf("Entered Number is ZERO");
    else
        if(num>0)
            printf("%d is a Positive Number",num);
        else
            printf("%d is a Negative Numbr",num);
}

 OUTPUT:

Enter a Number to test ZERO or +ve or -ve :10
10 is a Positive Number
Previous article: C Program for Sum of Squares of Numbers from 1 to n Prev Next article: C Program to Implement BINARY SEARCH Next
  • C Program to Convert Infix to Postfix Expression using Stack
  • Implementation of Queue using Array in C
  • C Program to Find Number of Characters and Words in a String
  • C program to Print Triangle Pattern
  • C Program to find Reverse of a Number
  • C Program to Calculate NCR
  • Fizz Buzz Implementation in C
  • C Program to INSERT a Sub-String in Main String at Given Position
  • C Program to Implement CONTINUE statement
  • C Program to Implement SHELL SORT
  • C Program to Find Given Number is Perfect or Not
  • Simulate Bankers Algorithm for Deadlock Avoidance Using C
  • C Program for Monthly Bill of a Newspaper
  • C Program to Find Sum of Even Integers
  • C Program to find Area of a Circle
  • Privacy Policy
  • Cookie Policy
© programming9.com 2025
Back to top