A worked example: the determinant of [[1,2],[3,4]]
The determinant of [[1,2],[3,4]] is −2 — for a 2×2 matrix [[a,b],[c,d]], that's simply ad − bc, or (1×4) − (2×3) = 4 − 6 = −2.
How larger matrices are actually computed: Gaussian elimination
For a 3×3 matrix like [[2,0,1],[1,3,2],[0,1,4]], the determinant is 21 — computed not by the cofactor-expansion formula taught by hand, but by reducing the matrix to upper-triangular form via Gaussian elimination (with partial pivoting for numerical stability) and multiplying the resulting diagonal entries. This scales far better to large matrices than cofactor expansion, whose cost explodes factorially with size.
The one number that decides invertibility: zero
[[1,2],[2,4]] has a determinant of exactly 0 — its second row is just double the first, making the rows linearly dependent. A zero determinant means the matrix is "singular": it has no inverse, and represents a transformation that collapses space into a lower dimension rather than a reversible one.
What a nonzero determinant's size and sign mean
Beyond just "invertible or not," a determinant's magnitude describes how much a matrix scales area (in 2D) or volume (in 3D) when used as a linear transformation, and its sign indicates whether that transformation preserves or flips orientation.
Why this matters before attempting to invert a matrix
Checking the determinant first is the standard way to know whether inverting a matrix is even possible before running the more expensive inversion computation — a singular matrix will always fail to produce an inverse, no matter which method is used.