# Lesson 2: The first function

Now that we’ve seen how to include formulas in Excel spreadsheets, we can get to the real deal: functions. Functions are basically formulas with names. It’s easiest to understand with an example.

The SUM function will sum the values that you give it. We can recreate the formula that we created in the previous exercise (`=32+57`), but using the SUM function. That would look like this: `=SUM(32,57)`

If you write this in a cell, it will show 89. Exactly as you may expect. But you can add more numbers (separated by commas) to the function: `=SUM(32,57,1)` will result in 90, for example.

### References

In this exercise, we will combine the SUM function with another interesting Excel feature: references. So what are references? Once again, an example will explain this very quickly. Look at the following formula: `=SUM(A1,A2)`

What do you think the result will be? It will be the value in cell A1 plus the value in cell A2. It’s that simple.

We know the SUM function will sum the values that you give it, but in this case, we give it references to cells. When you do that, it will instead sum the contents of the cells that you reference. So the result will be different depending on the values in cells A1 and A2.

These references can be super handy because they update automatically if the contents of the cells change. Whenever you edit the value in cell A1, the result of `=SUM(A1, A2)` will also automatically update! And that’s why references are so ridiculously useful.

Now, let’s get to the exercise. We will be using the SUM function to calculate our total monthly income after expenses. Use the SUM function in cell B7 to sum the values in the cells B2, B3, B4 and B5. That way, you will have calculated the total monthly income after expenses.