Skip to content

Integer calculator

Calculate with signed whole numbers exactly, including integer division with a quotient and remainder.

Enter integers

Your data stays in this browser.

Use signed base-10 integers up to 100 digits. Only absolute value uses one input.

Exact integer result

Enter the required integer values and choose Calculate.

How to use the integer calculator

  1. Choose addition, subtraction, multiplication, integer division, or absolute value. The second field is shown only when the selected operation needs it.
  2. Enter signed whole numbers with uninterrupted digits. Press Calculate or Enter; the inputs stay visible if an error needs correction.
  3. Read the exact result. Division reports both an integer quotient and remainder instead of rounding a decimal answer.
  4. Editing either value immediately removes the old result and disables Copy result. Clear removes inputs, errors, the result, and copy status while keeping the selected operation.

Operations and integer-division convention

Addition uses a + b, subtraction uses a − b, multiplication uses a × b, and absolute value |a| is the nonnegative distance from zero. BigInt arithmetic preserves every accepted digit.

For division, a = bq + r. This calculator truncates q toward zero, matching JavaScript integer arithmetic, and computes r = a − bq. Therefore a nonzero remainder has the same sign as the dividend a.

Example: −17 ÷ 5 gives q = −3 and r = −2 because −17 = 5(−3) + (−2). This differs from Euclidean division, which always chooses a nonnegative remainder. The convention is stated so negative cases are predictable.

Examples

Exact multiplication

123456789 × 987654321 equals 121932631112635269. No floating-point rounding is used.

Division with remainder

17 ÷ 5 returns quotient 3 and remainder 2. For −17 ÷ 5 it returns quotient −3 and remainder −2 under truncation toward zero.

Absolute value

Choose Absolute value and enter −42. The second input disappears and the result is 42.

Limits and error help

Frequently asked questions

Why is there no decimal quotient?

This page is specifically for integer arithmetic. Division exposes the whole quotient and remainder; use a decimal calculator when a fractional quotient is required.

Can I use negative numbers?

Yes. Every operation accepts signed integers. The remainder convention for negative dividends is described above.

Is zero an integer?

Yes. Zero is valid for all operations except as the divisor in division.

Are large results rounded?

No. Accepted inputs and outputs use exact integer arithmetic.

Why did the result disappear?

Any input or operation edit invalidates the earlier calculation. Calculate again before copying.