title: Python 3.x rounding behavior
body: <p>I was just re-reading <a href="http://docs.python.org/py3k/whatsnew/3.0.html" rel="noreferrer">What’s New In Python 3.0</a> and it states:</p>
  
  <blockquote>
    <p>The round() function rounding strategy and return type have changed.
    Exact halfway cases are now rounded to the nearest even result instead
    of away from zero. (For example, round(2.5) now returns 2 rather than
    3.)</p>
  </blockquote>
  
  <p>and
  the documentation for <a href="http://docs.python.org/release/3.1.5/library/functions.html#round" rel="noreferrer">round</a>:</p>
  
  <blockquote>
    <p>For the built-in types supporting round(), values are rounded to the
    closest multiple of 10 to the power minus n; if two multiples are
    equally close, rounding is done toward the even choice</p>
  </blockquote>
  
  <p>So, under <strong>v2.7.3</strong>:</p>
  
  <pre><code>In [85]: round(2.5)
  Out[85]: 3.0
  
  In [86]: round(3.5)
  Out[86]: 4.0
  </code></pre>
  
  <p>as I'd have expected. However, now under <strong>v3.2.3</strong>:</p>
  
  <pre><code>In [32]: round(2.5)
  Out[32]: 2
  
  In [33]: round(3.5)
  Out[33]: 4
  </code></pre>
  
  <p>This seems counter-intuitive and contrary to what I understand about
  rounding (and bound to trip up people). English isn't my native language but
  until I read this I thought I knew what rounding meant :-/  I am sure
  at the time v3 was introduced there must have been some discussion of
  this, but I was unable to find a good reason in my search.</p>
  
  <ol>
  <li>Does anyone have insight into why this was changed to this?</li>
  <li>Are there any other mainstream programming languages (e.g., <em>C, C++, Java, Perl,</em> ..) that do this sort of (to  me inconsistent) rounding?</li>
  </ol>
  
  <p>What am I missing here?</p>
  
  <p>UPDATE: @Li-aungYip's comment re "Banker's rounding" gave me the right search term/keywords to search for and I found this SO question: <a href="https://stackoverflow.com/questions/311696/why-does-net-use-bankers-rounding-as-default">Why does .NET use banker&#39;s rounding as default?</a>, so I will be reading that carefully.</p>