Clairaut's theorem
If a function's mixed partials are continuous, the order of differentiation doesn't matter — f_{xy}=f_{yx}.
Clairaut's theorem states that if f_{xy} and f_{yx} are both continuous on an open region, then f_{xy}=f_{yx} on that region. The continuity hypothesis is the entire content of the theorem, not fine print: a function can be built whose mixed partials both exist everywhere but aren't continuous at one point, and f_{xy}(0,0)\ne f_{yx}(0,0) actually happens there. Every function built from polynomials, exponentials, and trig functions has continuous partials of every order, so in practice the failure is a curiosity, not a daily concern.
Examples
For f(x,y)=x^3y^2-xy, both mixed partials equal 6x^2y-1, confirming Clairaut's theorem for this polynomial.