Question: DragonCurve.java Draw the dragon curve using Turtle API . The program has to ask the user to enter the iteration, the length of each segment

DragonCurve.java

Draw the dragon curve using Turtle API . The program has to ask the user to enter the iteration, the length of each segment in the curve and if the user would like to display the string of the dragon curve in terms of r/l. The program should display the string of the curve if the user entered yes and print the curve using Turtle API. You should assume that the initial state of the curve is a horizontal line. If the user enter iteration 2, then the string will be pre a program to write the instructions for drawing a dragon curve of a string of order n. ThThe instructions are strings rrl, which means R F R F L F, where the F means "draw line while moving segment unit forward", L means "turn left", and R means turn right.

DragonCurve.java Draw the dragon curve using Turtle API . The program has

to ask the user to enter the iteration, the length of each

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!