you can initiate objects from a 1

you can initiate objects from a

You can initiate objects from a Class. *Regards, Yousif Ayman Ahmed from Asyut-Egypt:)*

Here is what the above code is Doing:
1. We create a class called `Person`
2. We create a function called `__init__` which is a special function in Python.
3. We create a variable called `name` and assign it to the parameter `name`
4. We create a variable called `age` and assign it to the parameter `age`
5. We create a function called `myfunc` which takes `self` as a parameter.
6. We print out the `name` and `age` variables.
7. We create an object called `p1` and pass in `John` and `36` as parameters.
8. We call the `myfunc` function on the `p1` object.

Similar Posts