title: Why are float literals represented as are despite the error?
body: <p>My understanding is that floats are internally represented as binary expansion, and that introduces errors. If that is the case, then why are float literals represented as are given? Suppose that <code>0.1</code> is represented internally as <code>0.0999999999999999</code> according to binary expansion (I am using a fake example, just to show the point. This particular value is probably not correct.). Then in inspection or in the return value of irb, why does it/why is it possible to print the given literal <code>0.1</code> and not <code>0.0999999999999999</code>? Isn't the original literal form gone once it is interpreted and expanded into binary?</p>
  
  <p>In other words, a float literal-to-internal binary expression is a many-to-one mapping. Different float literals that are close enough are mapped to the same internal binary expression. Why then is it possible to reconstruct the original literal from the internal expression (modulo differences between <code>1.10</code> and <code>1.1</code>, <code>1.23e2</code> <code>123.0</code> as in Mark Dickinson's comment)?</p>