An arbitrary precision calculator in JavaScript