fork download
  1. #include <stdio.h>
  2.  
  3. int main () {
  4. int num;
  5. printf ("Enter the number \n");
  6. scanf ("%d", &num);
  7. printf ("The number entered is %d \n", num);
  8.  
  9. if (num < 0){
  10. printf ("The number is negative \n");
  11. }
  12. else{
  13. printf ("The number is positive \n");
  14. }
  15. return 0;
  16.  
  17. }
Success #stdin #stdout 0s 5320KB
stdin
23
stdout
Enter the number 
The number entered is 23 
The number is positive