Skip to main content
PulsarKit

Calculator

A standard and scientific calculator in one page, with proper operator precedence, memory keys, a running history and full keyboard support.

How to use the calculator

  1. 1

    Pick standard or scientific

    Standard covers the four operations, percentages and sign switching. Scientific adds brackets, powers, roots, logarithms, trigonometry, factorials and the constants pi and e.

  2. 2

    Type the expression

    Use the on-screen keys or your physical keyboard. Digits, operators, brackets and percent all work, Enter calculates and Backspace removes the last entry.

  3. 3

    Press equals and read the history

    The answer appears above the keypad and drops into the history list, where any earlier result can be clicked to reuse it in the next calculation.

Why this calculator answers 20, not 32

Type 12 + 4 × 2 into a cheap pocket calculator and it will usually answer 32, because it evaluates each operation the moment you press the next key. That is left-to-right evaluation, and it quietly ignores the rule that multiplication binds tighter than addition. This page parses the whole expression before evaluating any of it, so multiplication and division are resolved first, then addition and subtraction, and powers bind tighter still and associate to the right: 2^3^2 is 512, not 64. If you actually want the left-to-right reading, brackets make it explicit: (12 + 4) × 2 really is 32.

Percent behaves the way a pocket calculator taught you

Percent is not plain division by a hundred here, because that is rarely what people mean. When percent follows an addition or subtraction, it is read as a share of the first number: 200 + 10% gives 220, which is how you add tax or a tip. When it follows a multiplication, it is a plain hundredth: 200 × 10% gives 20. Both readings are standard on physical calculators, and the expression line above the result always shows exactly what was entered, so there is never a guess about which one applied.

Degrees, radians and the numbers that should be zero

The scientific mode has a degrees-and-radians switch, and the current setting is printed next to the result so a trigonometric answer is never ambiguous. Results that sit within a rounding error of a whole number are snapped to it: sin 180° prints as 0 rather than 1.22e-16, which is the floating-point residue of converting degrees to radians rather than a meaningful quantity. Undefined cases are refused rather than approximated: tan 90° reports an error instead of returning the enormous number that double precision happens to produce there.

Your calculations never leave this tab

Every expression is parsed and evaluated in JavaScript in your browser as you type. Nothing is uploaded, and the history list is kept in this tab's session storage only, so closing the tab erases it. Analytics records that a calculation happened and which mode was used, never the numbers or expressions themselves.

Frequently asked questions

Why does 12 + 4 × 2 equal 20 and not 32?

Because multiplication is evaluated before addition, as in standard mathematical notation. Calculators that answer 32 evaluate strictly left to right as you press keys. To get 32 here, put the addition in brackets: (12 + 4) × 2.

How does the percent key work?

Percent depends on the operation before it. After a plus or minus it is a share of the first number, so 200 + 10% is 220. After a multiplication or division it is a plain hundredth, so 200 × 10% is 20. This matches how physical calculators behave.

Does the scientific mode use degrees or radians?

Either. There is a switch in the options panel, and the active unit is shown next to the result. Degrees are the default, since that is what most people expect when typing sin 90 without further thought.

What do the memory keys do?

MC clears the stored value, MR inserts it into the expression you are building, M+ adds the current result to it and M− subtracts. A small M marker appears next to the expression whenever the memory holds something other than zero.

Can I use my keyboard instead of clicking?

Yes. Digits, a decimal point or comma, plus, minus, asterisk, slash, caret, brackets, percent and factorial all type directly. Enter or the equals key calculates, Backspace removes the last entry and Escape clears everything.

How many decimal places does the result show?

Ten by default, adjustable from 0 to 14 in the options panel. Calculations always run at full double precision and rounding is applied once, at the moment of display, so a shortened display never feeds a rounded number into the next step.

Why does the calculator refuse some expressions?

Square roots and logarithms of negative numbers, the logarithm of zero, tangents of right angles and factorials of fractions have no real answer, so an error is shown instead of a misleading number. Dividing by zero and results too large for accurate display are refused for the same reason.

Are my calculations sent to a server?

No. The parser and evaluator run entirely in your browser, and the history never leaves this tab. There is no upload step and no account, so there is nothing for anyone to read afterwards.

Guides

Related tools