Skip to content

Instantly share code, notes, and snippets.

@arnemart
Created November 11, 2015 08:51

Revisions

  1. arnemart created this gist Nov 11, 2015.
    3 changes: 3 additions & 0 deletions lastNDigitsOfPi.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,3 @@
    function lastNDigitsOfPi(n) {
    return Math.PI.toFixed(Infinity).slice(-n);
    }