2
I was doing some experiments and I would like to calculate the 1,000 first decimal places of the Euler constant (as demonstrated on this website http://www.profcardy.com/cardicas/constantes.php), then did this program in javascript:
(function euler(){
var f;
var c = 0;
var n = 1;
var fx = 0;
while (c <= 10000){
f = (1+(1/n));
fx = Math.pow(f,n);
console.log(Number.MAX_VALUE, fx);
n++;
c++;
}
})();
When running on the console the last result was 1.7976931348623157e+308 2.7181459404132355. How do I display them to the 1,000 first decimal places as in the example given on the site? It can be in javascript or any other language. I found that question Decimal places in Javascript, but without the resolution I need.