File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 5858# -- CONSTRUCTING an instance of a CLASS, e.g.
5959# rg.SimpleTurtle()
6060# -- ASSIGNING the resulting OBJECT (instance of a class) a NAME, e.g.
61- # dave = rg.SimpleTurtle()
61+ # natasha = rg.SimpleTurtle()
6262# -- Applying a METHOD to an object to make the object DO something, e.g.
63- # dave .forward(100)
63+ # natasha .forward(100)
6464# -- Accessing an INSTANCE VARIABLE of an object, e.g.
65- # dave .speed = 10
66- # print(matt .speed)
65+ # natasha .speed = 10
66+ # print(boris .speed)
6767#
6868# After you are confident that you understand all the code below,
6969# change this TO-DO to DONE and ** continue to the next TOD-DO (below). **
122122# TODO: 5.
123123# The above code CONSTRUCTS two SimpleTurtle objects
124124# and gives those objects NAMES:
125- # dave matt
125+ # boris natasha
126126#
127127# Add code of your own that constructs another SimpleTurtle object,
128128# naming it whatever you want. Names cannot have spaces or special
You can’t perform that action at this time.
0 commit comments