00:01
To do, we're going to be creating a car class in python.
00:04
So to get started, we're going to create a class, and we'll call it car.
00:12
So here we're going to create our constructor.
00:23
So we have self, another parameter, and here we're going to do self -mod model year.
00:40
Model year is going to be equal to zero.
00:42
Self -dot purchase history, or purchase price, would be zero, and self -dot, curve value, it'll be zero.
01:03
Right, so now let's create another function, and it's going to calculate the current value, so curve, and we're going to have our parameters, and cur year, current year.
01:30
Self.
01:31
That current value is going to be equal to a rounded self purchase.
01:46
Purchase price.
01:49
Purchase variable times minus 0 .15.
02:02
And then to the power of the current year minus self.
02:14
Model year.
02:17
Right.
02:20
So we're done with that.
02:22
So let's get another one.
02:24
Another function and it's going to be print info.
02:32
Self as our prompeter cars, car information.
02:48
Model year.
02:53
It's going to be self -stop model year.
03:01
Purchase price.
03:06
Self -dot purchase.
03:11
Copy in pieces, the variable name in here.
03:15
And print.
03:16
Current by which is this.
03:25
So now let's come out of here and create our main...