andrei31

Untitled

Jun 26th, 2011
418
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.20 KB | None | 0 0
  1. #include <stdio.h>
  2.  
  3. int main() {
  4.     float f = 0.0f;
  5.     int i;
  6.    
  7.     for(i=0; i<10; i++)
  8.         f += 0.1f;
  9.  
  10.     if (f == 1.0f)
  11.         printf("f is 1.0\n");
  12.     else
  13.         printf("f is NOT 1.0\n");
  14.  
  15.     return 0;
  16. }
Advertisement
Add Comment
Please, Sign In to add comment