If f[g(x)] = x, then f(x) and g(x) are inverses of each other.

Why? I don't get this in my math question.