Track object settings and drawn copies

A drawing app stores two independent circle objects, A and B. Initially, A has radius 12 px and outline width 2 px; B has radius 20 px and outline width 3 px.


Two separate circle objects have different initial radii and outline widths.


In the pseudocode below, set_radius replaces only the named object's radius, and set_outline replaces only its outline width. Both accept values in pixels. The command draw_copy draws a snapshot, a copy of the object's appearance at that moment. Each copy is placed in a separate, non-overlapping location. Later object changes do not alter copies already drawn.


Plain text
A.set_radius(18)
draw_copy(A)          # Copy 1
B.set_outline(5)
draw_copy(B)          # Copy 2
A.set_outline(4)
B.set_radius(14)
draw_copy(A)          # Copy 3
draw_copy(B)          # Copy 4


Complete the table with the radius and outline width of each drawn copy. Enter exact integers in pixels.

Drawn copySource objectRadius (px)Outline width (px)
Copy 1A
Copy 2B
Copy 3A
Copy 4B

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors