We've seen how we can pass values into a function as parameters by passing values like the name or department in the example earlier. But what about getting values out of a function? This is where the concept of return values comes to play. The work that functions do can produce new results. Sure, we can print the results on the screen, but what if we wanted to use those results later in our script or didn't want to print them at all? We can do this by returning values from the functions we defined ourselves. Let's go back to calculating the area of a triangle. Do you remember our triangle example from our earlier exercise? The area of the triangle is calculated as base times height divided by 2. Imagine we need to calculate this value several times in our code. It would be useful to have a function that does this for us. Check out how this would look. We use the keyword return to tell Python that this is the return value of a function. When we call the function, we store that value in a variable. Let's say we have the two triangles and we want to add up the sum of both areas. Here's what we would do. First, we calculate the two areas separately. Then, we add the sum of both areas together. Finally, we print the result converting it to a string. As you can see in this example, the area of triangle function returns a value which is not surprisingly the area of the triangle. We store that value in a different variable for each call to the function. In this case, area_a and area_b. Then we operate with those values adding them into the variable called sum and only printing this final result. This shows the power of the return statement. It allows us to combine calls to functions and to more complex operations which makes your code more reusable. Return statements in Python are even more interesting because we can use them to return more than one value. Let's say you have a duration of time in seconds and you want to convert that to the equivalent number of hours, minutes, and seconds. Here's how to do that in Python. Did you spot the new operator in this function? That double slash operator is called floor division. A floor division divides a number and takes the integer part of the division as the result. For example, five slash slash two is two instead of 2.5. In our example, the first operation is calculating how many hours are in a given amount of seconds. While the second works out how many minutes are left once we subtract the hours and then how many seconds remain after subtracting minutes. We end up with three numbers as a result. So the function returns all three of them. Let's see what this looks like when we're calling a function. Because we know that the function returns three values, we assign the result of the function to three different variables. There's one last thing we should call out about returning values. It is possible to return nothing and that's perfectly okay. Let's look at an example from an earlier video. Here the function just printed a message and didn't return anything. What do you think would happen if we try to assign the value of this function to a variable? Let's try it out and see. Here when we call the function it printed a message just like we expected. We stored the return value in the result variable, but there was no return statement in the function. So the value of results is none. None is a very special data type in Python used to indicate that things are empty or that they return nothing. Wow. That was a lot to learn about functions and the return values. Remember that the key to getting this right is to practice writing the code you've just learned as many times as you need. Functions and return values can be tricky concepts to master, but they let us do a bunch of cool stuff. So put the time and effort into learning for some really valuable returns.