about summary refs log blame commit diff stats
path: root/js/pi.js
blob: b15e62f0342ce9a17341290fdeb16d08da688a0f (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14













                                                       
// read in pi, ../10000.pi.txt

const fs = require('fs');

fs.readFile('../10000.pi.txt', 'utf8', (err, data) => {
  if (err) {
    console.error(err);
    return;
  }
  const string_pi = data;
  const big_pi = parseFloat(data);
  console.log(big_pi);
});