fork(1) download
  1. #include <stdio.h>
  2.  
  3. int main()
  4. {
  5. float f = 0.3;
  6. f -= 0.2;
  7. f -= 0.1;
  8.  
  9. if (!f)
  10. {
  11. printf("zero\n");
  12. }
  13. else
  14. {
  15. printf("non zero\n");
  16. }
  17.  
  18. if (f == 0)
  19. {
  20. printf("zero\n");
  21. }
  22. else
  23. {
  24. printf("non zero\n");
  25. }
  26.  
  27. return 0;
  28. }
Success #stdin #stdout 0s 2248KB
stdin
Standard input is empty
stdout
non zero
non zero