A few hundred years ago the glorious leader of a big country wanted to reward the creator of the chess game. The creator of the game simply wanted one grain of rice put on the first square of the chessboard, two grains on the second, then doubling it for every remaining square. The glorious leader had one thing in common with the our present day leaders, he had no idea about basic mathematical concepts. So he acted surprised by the humble request, had his helpers bring a bag of rice and started to fill the squares.
Did the creator of the chess game get a decent reward? Here is a simple Python program to do the counting.
Corrected the code after looking at the loop result prints.