title: How does exponent bias make comparison easier
body: <p>I'm reading <a href="https://en.wikipedia.org/wiki/Exponent_bias" rel="nofollow">this</a> article about <code>exponent bias</code> in floating point numbers and it says the following:</p>
  
  <blockquote>
    <p>n IEEE 754 floating point numbers, the exponent is biased in the
    engineering sense of the word – the value stored is offset from the
    actual value by the exponent bias. Biasing is done because exponents
    have to be signed values in order to be able to represent both tiny
    and huge values, but two's complement, the usual representation for
    signed values, would make <strong>comparison</strong> harder. To solve this problem the
    exponent is biased before being stored, by adjusting its value to put
    it within an unsigned range suitable for <strong>comparison</strong>. By arranging the
    fields so that the sign bit is in the most significant bit position,
    the biased exponent in the middle, then the mantissa in the least
    significant bits, the resulting value will be ordered properly,
    whether it's interpreted as a floating point or integer value. This
    <strong>allows high speed comparisons</strong> of floating point numbers using fixed
    point hardware.</p>
  </blockquote>
  
  <p>I've also found this explanation from wikipedia's <a href="https://en.wikipedia.org/wiki/Offset_binary" rel="nofollow">article</a> about offset binary:</p>
  
  <blockquote>
    <p>This has the consequence that the "zero" value is represented by a 1
    in the most significant bit and zero in all other bits, and in general
    the effect is conveniently the same as using two's complement except
    that the most significant bit is inverted. It also has the consequence
    that <strong>in a logical comparison operation</strong>, one gets the same result as
    with a two's complement numerical comparison operation, whereas, in
    two's complement notation a logical comparison will agree with two's
    complement numerical comparison operation if and only if the numbers
    being compared have the same sign. Otherwise the sense of the
    comparison will be inverted, with all negative values being taken as
    being larger than all positive values.</p>
  </blockquote>
  
  <p>I don't really understand what kind of comparison they are talking about here. Can someone please explain using a simple example?</p>