English, asked by zain342062, 5 months ago

write a c++ program to check whether a number is negative positive or zero​

Answers

Answered by sougatap57
0

Answer:

#include <iostream>

using namespace std;

int main(){

   int a;

   cout<<"enter the number";

   cin>>a;

   if(a>0)

   {

       cout<<"positive";

   }

   else if(a<0)

   {

       cout<<"negative";

   }

   else{

       cout<<"zero";

   }

   return 0;

}

Output

enter the number 6

positive

Similar questions