write a c++ program to find whether a number is positive or negative.


Source code-
#include<iostream>
using namespace std;
int main(){
int number;
cout<<"Enter a number ";
cin>>number;
if(number>0)
cout<<"Negative";
else
cout<<"Positive";
}
OUTPUT-
Enter a number 5
Negative

Comments

Popular posts from this blog

cpanel exam CPSP Answers

How to install zimbra collaboration suite 8.8.11 on CentOS 7

awstats installation