title: What's the difference between float and double?
body: <p>When I run the following code , </p>
  
  <pre><code>NSString* s= @"10000000.01";
  float f = [s floatValue];
  double d = [s doubleValue];
  
  if(f &gt; 10000000)
  {
      NSLog(@"Over Value");
  }
  else {
      NSLog(@"OK Float");
  }
  
  if(d &gt; 10000000)
  {
      NSLog(@"Over value");
  }
  else {
      NSLog(@"OK Double");
  }
  </code></pre>
  
  <p>The response is like following.</p>
  
  <pre><code>2013-04-19 17:07:29.284 float[2991:907] OK Float
  2013-04-19 17:07:29.287 float[2991:907] Over value
  </code></pre>
  
  <p>Why float value changed to 10000000.00 instead of 10000000.01 ?</p>