<aside> ✅ Object Oriented Programming (OOP) helps us to have benefit
<aside> ✅ Waiter: (real world object)
what it has? like Attributes
what it does? like Methods of take_order, take payment (naming shall be 動詞 + 名詞, that’s general rule in OOP world)
what is Class? a Type, Class named by First word is upper case.
Ex, car (object) = CarBlueprint (Class)
what is Object? generated object by Class </aside>
<aside> ✅ Car
turtle - Turtle graphics - Python 3.10.2 documentation
day16 practice code:
#Option 1:
import turtle
tinny = turtle.Turtle()
#Option 2:
from turtle import Turtle, Screen
tinny = Turtle()
tinny.shape("turtle")
tinny.color("red","green")
#docs.python.org/3/library/turtle.html
myScreen = Screen()
print(myScreen.canvheight)
myScreen.exitonclick()
PyPI · The Python Package Index