What are the names of the instances in the following code? Please put one instance per blank space and enter them in the order that the computer would read them.
import turtle
wn = turtle.Screen()
jazz = turtle.Turtle()
jazz.forward(50)
jazz.right(90)
pop = turtle.Turtle()
pop.left(180)
pop.forward(76)
Answers
Answered by
3
Instances in order are :
1. wn
2. jazz
3. pop
Explanation :
- Instances are nothing but the objects.
- Here, firstly, wn creates a graphical user interface window.
- jazz is the object that creates a turtle point over the window formed. and the next statement draws a line of 50 pixels towards the East as the turtle defaultly faces East direction. And then changes its direction by 90° right.
- And then another turte object named pop is created over the window screen which in the next statement turns 180° left, and then with the next statement goes 76 pixels forward in the direction it is facing.
- Any number of turtle objects can be created in a code.
Learn more :
1. Program to perform Arithmetic operations using function.
https://brainly.in/question/18905944
2. Write a simple python function to increase the value of any number by a constant "C=5"
https://brainly.in/question/16322662
Similar questions