fork download
  1. #include <stdio.h>
  2.  
  3. int main()
  4. {
  5. int i, numb, counter = 0;
  6. printf("enter 8 numbers\n");
  7.  
  8. while(scanf("%d", &numb) != EOF)
  9. {
  10. counter++;
  11. }
  12.  
  13. if (counter < 8)
  14. {
  15. printf("not enough numbers\n");
  16. //exit(1);
  17. }
  18.  
  19. return (0);
  20. }
Success #stdin #stdout 0s 2116KB
stdin
1
2
3
4
5
stdout
enter 8 numbers
not enough numbers