Test 6 Edhesive Term 2

Réussis tes devoirs et examens dès maintenant avec Quizwiz!

Check ALL of the correct answers. What would the following for loop print? for i in range(2, 4): print(i)

3,2

In the following circle command, the radius is _____________. canvas.draw_circle((140, 100), 50, 15, "Black")

50

The point (6, 8) is

A

The point (8, 6) is

B

*Which of the following will print a vertical line?

canvas.draw_line((100, 140), (100, 140), 4, "Black") (WRONG ANSWER)

The point (1, 3) is

D

*Consider the following command: canvas.draw_circle((A1, A2), B, C, D) Which represents the line thickness?

D (WRONG ANSWER)

The following statement draws a ______________ line. canvas.draw_line ((140, 140), (100, 100), 4, "Black")

Diagonal Line

Which command tells the for loop what to count by?

Range

Which color is created by: RGB (255, 0, 0)

Red

Colors in graphics are represented by a ____________ data type.

String

Which of the following is drawn by: for x in range(100, 140, 10): canvas.draw_polygon ([(x, x), (x + 20, x), (x + 20, x + 20), (x, x + 20)], 2, "Black", "White")

The one with a stack of squares

Which of the following is NOT true about for loops:

They are used to replace user input while loops.

What is returned by the code: range (5, 100, 25) ?

[5, 30, 55, 80]

Which of the following will output:

canvas.draw_circle((150, 150), 50, 1, "Black", "White")

*Write two lines of code to draw the following circles centered at 600,600. The radius of the smallest circle is 200. There are 50 points between the larger circle and the smaller circle. Which of the following draw these circles?

canvas.draw_circle((600, 600), 200, 3, "Black") canvas.draw_circle((650, 650), 200, 3, "Black") (WRONG ANSWER)

Which of the following correctly draws a point on the screen?

canvas.draw_point((123, 125), "Red")

Which of the following will output a box?

canvas.draw_polygon([(150, 50),(150, 150),(50, 150),(50, 50)], 1, "Black")

Which of the commands below would be most helpful if you were trying to create a face shape for your emoticon?

draw_circle

Which command correctly draws strings on the screen?

draw_text


Ensembles d'études connexes

Histoire Révolution Française date

View Set

CHF 4400 - Greenberg: Chapter Three

View Set

Matt's CFCM Questions: FAR Part 32. Contract Financing

View Set

Stats 118 - Chapters 1-8 Homework, In-class Activities & Excel Labs

View Set

Networks Final Exam REVIEW PART 2

View Set

Fundamentals for Success in Business

View Set