Freigeben über


Get-OneMillionDigitsofPi

After showing a customer the PI static method of System.Math, they asked, "how do I get more digits?".

capture198

 

A quick bit of lateral-thinking, i.e. cheating, later and a with more than a nod to the hard work done by the folks at angio.net, here's the wonderfully named Get-OneMillionDigitsOfPi function.

 

 
function Get-OneMillionDigitsOfPi {

    (Invoke-WebRequest -Uri "https://www.angio.net/pi/digits/pi1000000.txt").Content
    
}

Let's run it...

capture199

 

And, just to make sure we're getting value for money...

capture200