A small, clear language
Use decimal or scientific notation, parentheses and + − * / % (or × and ÷). The % operator returns a remainder; use /100 for a percentage. Write multiplication explicitly: 2*(3+4).
Use Math.pow(2,3) for powers. The ^ symbol, leading-zero/octal notation, assignments and programming statements are not supported.
Functions and constants
Math.abs, sqrt, pow, sin, cos, tan, asin, acos, atan, atan2, log, exp, floor, ceil, round, min and max. Prefix every function with Math. Natural logarithms use Math.log.
Constants: Math.PI, Math.E, Math.LN2, Math.LN10, Math.LOG2E, Math.LOG10E, Math.SQRT2, Math.SQRT1_2. Expressions are limited to 512 characters, 32 nested levels and 16 arguments per function. Round sends halfway values toward positive infinity. Floating-point underflow may round a tiny result to zero.