Popular recipes tagged "power_of_two" but not "library"http://code.activestate.com/recipes/tags/power_of_two-library/2010-11-28T16:05:19-08:00ActiveState Code RecipesPower Of Two (Python) 2010-11-28T16:05:19-08:00Thomas Lehmannhttp://code.activestate.com/recipes/users/4174477/http://code.activestate.com/recipes/577475-power-of-two/ <p style="color: grey"> Python recipe 577475 by <a href="/recipes/users/4174477/">Thomas Lehmann</a> (<a href="/recipes/tags/power_of_two/">power_of_two</a>). </p> <ul> <li>It's a simple algorithm doing nearly the same what you can do when calculating a multiplication on a piece on paper.</li> <li>In python you don't need this. You simply say 2**n and you have it; so see it as prototyping for a final C/C++ program where you are limited by the given datatypes ... as long you don't write a 'BigNumber' class.</li> </ul>