# FOIL Calculator

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

> The FOIL calculator multiplies two binomials (ax + b)(cx + d) using First, Outer, Inner, Last, and can also run in reverse to factor a trinomial back into binomials.

## Inputs

- Mode
- a
- b
- c
- d

## Results

- Result
- FOIL steps
- x² coefficient
- x coefficient
- Constant

## Formula

```
(ax + b)(cx + d) = acx² + (ad + bc)x + bd
```

## Explanation

FOIL is a memory aid for multiplying two binomials: multiply the First terms, the Outer terms, the Inner terms and the Last terms, then combine the two middle products. It is a special case of the distributive property.

### How to use the FOIL Calculator

- **Mode**
- **a**
- **b**
- **c**
- **d**

Everything is calculated in your browser, so results appear instantly and nothing you type is sent to a server.

### How it works

The four products are listed separately, then the Outer and Inner products – both x-terms – are combined. In reverse mode the calculator factors ax² + bx + c instead.

## Worked example

Inputs — Mode: Multiply (ax + b)(cx + d); a: 2; b: 3; c: 1; d: -4.

Results — **Result = 2x² − 5x − 12**; FOIL steps = First: 2x · x = 2x²
Outer: 2x · (−4) = −8x
Inner: 3 · x = 3x
Last: 3 · (−4) = −12
Combine like terms: 2x² − 5x − 12; x² coefficient = 2; x coefficient = −5; Constant = −12.

## Key terms

- **Binomial**: A polynomial with two terms.
- **Distributive property**: a(b + c) = ab + ac.

## FAQ

**What does FOIL stand for?**
First, Outer, Inner, Last – the four products when multiplying two binomials.

**Does FOIL work for trinomials?**
No. For longer polynomials, multiply every term by every term (the distributive property).

**What is (x + 3)(x − 3)?**
x² − 9, a difference of squares: the outer and inner terms cancel.

**What is reverse FOIL?**
Factoring: finding the binomials that multiply to a given trinomial.


## Sources

- [OpenStax – College Algebra 2e](https://openstax.org/details/books/college-algebra-2e)
- [OpenStax – Intermediate Algebra 2e](https://openstax.org/details/books/intermediate-algebra-2e)
