fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int x;
  6. cout<<"enter the number :"<<endl;
  7. cin>>x;
  8. if(x>0){
  9. cout<<"postive"<<endl;
  10. }
  11. else if(x=0){
  12. cout<<"zero :"<<endl;
  13. }
  14. else{
  15. cout<<"negative"<<endl;
  16. }
  17. return 0;
  18. }
Success #stdin #stdout 0.01s 5332KB
stdin
Standard input is empty
stdout
enter the number :
negative