PowerShell for Windows Admins

Aug 29 2014   2:29PM GMT

Grains of rice on a chess board

Richard Siddaway Richard Siddaway Profile: Richard Siddaway

There is a story about the inventor of chess being rewarded by putting 1 grain of rice on the first square of the board; 2 on the second and so on.  How much rice does that come to?

 

The total number of grains is 1.84467440737096E+19

 

At 25mg per grain thats 461168601842739 kilogrammes of rice

 

Which in more understandable terms is:

 

461,168,601,842.739 metric tonnes

 

or
453,886,749,619.642 tons

 

That’s a lot of rice

 

If you want to play around with the numbers the calculations are:

 

[double]$result = 0

1..64 |
foreach {

$square = [math]::Pow(2, ($psitem -1))
$result += $square

}

$wt = 0.025

$totalweight = ($wt * $result)/1000
$totalweight

$mtwt = $totalweight /1000
$mtwt

$tons = $totalweight * 0.00098421
$tons

 Comment on this Post

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when other members comment.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to: