Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Exercise 5.3 (navigate3 py) Modify navigate py so that, father than take instructions from the command line, feuds from a ile (specified by user input)

image text in transcribed
Exercise 5.3 (navigate3 py) Modify navigate py so that, father than take instructions from the command line, feuds from a ile (specified by user input) to determine what the turtle will do. Additionaly, you will be adding the "spit" command. This command will use instantiation of new turtles in onder to draw multiple lines at once. Every new command will apply to every trtle that currently exists. The Sle will have on instruction per line. The possible instnacticns ane forward X Move all turtles forwand X left X Turn all tartles X degrees to the left rightX Tum all turties X degrees to the right. split X Create a new copy ofevery turtle Each new turtle will be turned X degrees to the right Sample inpat fik Defe 20 s aplit 40 apLit 40 fervard ptit 40 u split 40 u fervard 0 Sample output CSE/IT 107L Lab 10 Review and Markow Chaires e Write a function for each command Keep a list of turtles Tostore a new turtle in a variable named t, write t Turtle Use t elene to clone the burtle t when processing the split commmand. Add this new turtle to your list of turtles Exercise 5.3 (navigate3 py) Modify navigate py so that, father than take instructions from the command line, feuds from a ile (specified by user input) to determine what the turtle will do. Additionaly, you will be adding the "spit" command. This command will use instantiation of new turtles in onder to draw multiple lines at once. Every new command will apply to every trtle that currently exists. The Sle will have on instruction per line. The possible instnacticns ane forward X Move all turtles forwand X left X Turn all tartles X degrees to the left rightX Tum all turties X degrees to the right. split X Create a new copy ofevery turtle Each new turtle will be turned X degrees to the right Sample inpat fik Defe 20 s aplit 40 apLit 40 fervard ptit 40 u split 40 u fervard 0 Sample output CSE/IT 107L Lab 10 Review and Markow Chaires e Write a function for each command Keep a list of turtles Tostore a new turtle in a variable named t, write t Turtle Use t elene to clone the burtle t when processing the split commmand. Add this new turtle to your list of turtles

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

Students also viewed these Databases questions