fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. int n;
  5. printf("enter a number : ");
  6. scanf("%d",&n);
  7. if(n<0)
  8. printf("negative number:%d\n",n );
  9. else if(n>0)
  10. printf("positive number:%d\n",n);
  11. if(n==0)
  12. printf("zero number:%d",n);
  13. // your code goes here
  14. return 0;
  15. }
  16.  
Success #stdin #stdout 0.01s 5288KB
stdin
9
stdout
enter a number : positive number:9