Explore
Courses
Batches
Sketches
Statistics
Code a Pookkalam
Jobs
Devsprint
People
Course Creation
Create a Course
Guidelines
Resources
Support
Blogs
My Profile
About Us
Login
Sketches
0
New Sketch
By
Ananya R
Run
def concentric_rectangle(x, y, r, n): step = r/n for i in range(n): c = rectangle(x=x, y=y, w=r, h=r) show(c) r = r-step w, h = 200, 200 r = 200 n = 10 concentric_rectangle(0, 0, r, n) concentric_rectangle(w/2, w/2, r/2, 5) concentric_rectangle(-w/2, -w/2, r/2, 5) concentric_rectangle(w/2, -w/2, r/2, 5) concentric_rectangle(-w/2, w/2, r/2, 5)
Comments
Want to discuss?
Post it here, our mentors will help you out.
Login