A basic calculator in JavaScript