Mathematics
Using Generating Functions to Solve Combinatorial Problems
Quick fact
Using generating functions, the number of ways to roll two six-sided dice and get a sum of 7 is found by extracting the coefficient of x^7 in (x + x^2 + ... + x^6)^2, which equals 6.
Why this is interesting
Imagine being able to solve a tricky counting problem by just doing algebra on a fancy polynomial. Generating functions turn counting into algebra, and once you see the trick, a whole world of problems becomes surprisingly simple.