Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Can someone please help me code this in python? By default, you will be facing to the right, ensure to turn left by 120 Then,

Can someone please help me code this in python?

image text in transcribed

By default, you will be facing to the right, ensure to turn left by 120 Then, set the background to black and pen colour to magenta as well as the pen width to 2

To draw a single pentagon:

Loop SIX times (yes, six times, not five) to position the turtle at different corner each time

The very first pentagon will have a size of 10 + 2 units (*size" is the length of each side of the pentagon)

The second pentagon will have a size of 10 + 6 units The third pentagon will have a size of 10 + 10 units The fourth pentagon will have a size of 10 + 14 units, and so on...

The rotation angle will be the same as drawing an ordinary pentagon

After each iteration of drawing a pentagon, turn to the right by 1 degree

All in all, there will be 85 pentagons drawn

using i and j as the outer and inner variable names for the loops, respectively

Assignment 1 - Jonny Smith - js 222

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions

Question

How many multiples of 4 are there between 10 and 250?

Answered: 1 week ago

Question

What is the environment we are trying to create?

Answered: 1 week ago

Question

How can we visually describe our goals?

Answered: 1 week ago