 In the previous video, we learned to set up the state variables for our box class. Here's the code showing the initializer method. Now let's write the method to calculate the box's volume. We start with DEF and the name, and there's one parameter, self, again that refers to the object whose volume we want. Now we'll calculate the volume as self.length times self.width times self.height. You need the dot notation here. Remember that self means the current object, so we want to multiply the current object's length times the current object's width times the current object's height, and then return the result. Now I can get the box's volume by saying capacity becomes box1.volume and I can print that out. Box volume is capacity, and let's give it three decimal places, cubic units, and sure enough it works. There's something you may have noticed in the code. The volume method has one parameter, but we don't have any arguments when we call the method. What's going on here? Remember that self stands for the object we're working with. What's happening behind the scenes is that the object is treated as if it were the first argument, which provides the value for self. Now, back to our methods. The surface area method also takes self as a parameter, and you might be tempted to use the name area for the result of the calculation. But don't do that. It is never a good idea to name a variable the same as a function or method. In fact, some programming languages don't even allow you to do it. Instead, use another name. Result is usually a good choice. And then our formula, which is twice the length times the width of the object we're working with, plus the object's width times its height, plus the object's height times its length, and return that result. And then similarly, let's define our diagonal, which takes an object and gives back the square root of the length squared plus width squared plus height squared and returns that result. Now let's call those methods. Surface becomes box one dot area, and diagonal becomes box one dot diagonal. And print the results. Surface area is square units, and the diagonal is diagonal units. And run the program, and there are our answers. And that's how you write and call methods for objects.