recentpopularlog in

orphu : return   339

« earlier  
A Million Digits of Pi in 9 Lines of Javascript
let i = 1n;
let x = 3n * (10n ** 1020n);
let pi = x;
while (x > 0) {
x = x * i / ((i + 1n) * 4n);
pi += x / (i + 2n);
i += 2n;
}
console.log(pi / (10n ** 20n));
pi  javascript  chrome  cool  math  2019  return  programming  algorithms  fun  interesting 
september 2019 by orphu
« earlier      
per page:    204080120160

Copy this bookmark:





to read