# Integer Calculator

URL: https://speedycalculator.com/calculators/math/integer/
Last updated: 2026-10-30

> The integer calculator adds, subtracts, multiplies and divides integers (positive and negative whole numbers), and also raises to powers, takes roots and logarithms; division also gives the quotient and remainder.

## Inputs

- Operation
- a
- b

## Results

- Result
- Integer quotient (division)
- Remainder (division)

## Formula

```
a + b, a − b, a × b, a ÷ b (= q remainder r), aᵇ, ᵇ√a, log_a b
```

## Explanation

Integers are the whole numbers and their negatives. The sign rules – a negative times a negative is positive, subtracting a negative is adding – are the main source of mistakes, and this calculator applies them for you.

### How to use the Integer Calculator

- **Operation**
- **a**
- **b**

Results update as you type, and everything is calculated in your browser.

### How it works

Results are exact for whole-number operations within about 15 digits. For division, the integer quotient and remainder are given as well as the exact value.

### Inputs explained

FieldWhat to enterOperationChoose one: Addition (a + b), Subtraction (a − b), Multiplication (a × b), Division (a ÷ b) …aA numberbA number

### What each result means

- **Integer quotient (division)** = trunc([a]÷[b])
- **Remainder (division)** = [a] - [b]×trunc([a]÷[b])

### Example values

How the main result changes when **a** changes and everything else stays at the example values above:

aResult-8.5-1.7-12.75-2.55-17-3.4-21.25-4.25-25.5-5.1-34-6.8

## Worked example

Inputs — Operation: Division (a ÷ b); a: -17; b: 5.

Results — **Result = -3.4**; Integer quotient (division) = -3; Remainder (division) = -2.

## Key terms

- **Integer**: A whole number, positive, negative or zero.

## FAQ

**What is −17 ÷ 5?**
−3.4, or −3 remainder −2 (truncated division).

**What is a negative times a negative?**
A positive number: (−4) × (−3) = 12.

**What is subtracting a negative?**
Adding: 5 − (−3) = 8.

**Is zero an integer?**
Yes – it is neither positive nor negative.


## Sources

- [OpenStax – Prealgebra 2e](https://openstax.org/details/books/prealgebra-2e)
- [OpenStax – Contemporary Mathematics](https://openstax.org/details/books/contemporary-mathematics)
