Modular forms are complex analytic functions on the upper half plane satisfying a certain kind of functional equation and growth condition. In this talk we will see how the theory of modular forms answers a classical problem in number theory, namely: "Which natural numbers can be represented as the sum of four squares, and in how many ways can that be done?".