Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Hello I need help modifying my code so that it allows different numbers of petals Please see image for further information Nothing fancy I am

image text in transcribedHello I need help modifying my code so that it allows different numbers of petals
Please see image for further information
Nothing fancy I am still learning python 3
Unttled Notepad File Edit Format View Help #3.3.1. Modify the flower function so tha #additional parameter: flower(tortoise, fcolor, length, petals) Note that the original function has the turtle travel ta total of 8 135 1888 degrees awhen you generalize the number of petals, make sure that the total number of degrees is still a multiple of 360 import turtle import math t it allows different numberswof petals. The revised function will need to take an def blossum(tortoise, fcolor, length, petals): tortoise.pencolor('red') tortoise.fillcolor(fcolor) tortoise.begin_fill0 radius368 tortoise.circle(radius, steps) tortoise.forward(length) for meh in range(8) #tortoise, forward(length) tortoise.left (135) tortoise.end_fill) def stem(tortoise, length): tortoise.pencolor( ereen') tortoise.pensize(length /20) tortoise.up) tortoise.forward(length 2) tortoise.down() tortoise.right (90) tortoise.forward(length) def flower(tortoise, fcolor, length, petals): blossum(tortoise, fcolor, length, petals) stem(tortoise, length) rainbow turtle.Turtle) rainbow.hideturtle) flower(rainbow, 'yellow, 2ee, 6) O Type here to search

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

Pro PowerShell For Database Developers

Authors: Bryan P Cafferky

1st Edition

1484205413, 9781484205419

More Books

Students also viewed these Databases questions