# data sturctures

Anonymous

Question description

I need python

CS 222 01 Program Assignment 05 – Chapter 04 20 Points Due: Tuesday, November 15, 2016 Design and test a recursive function that accepts two arguments into the parameters x and y. The function should return the value of x times y. Remember, multiplication can be performed as repeated addition as follows: 7X4=4+4+4+4+4+4+4 YOU MUST USE A RECURSIVE FUNCTION TO SOLVE THIS PROBLEM. Test the function with at least 2 different sets of values. Add the following comments to the beginning of the program. Name: Your Name Class and Section: CS 222 01 Assignment: Program Assignment 05 Due Date: See above Date Turned in: Program Description: You write a short description of what the program will do When you complete the program, do the following. 1. Create a folder with the following name: ProgramAssignment05 2. Copy your program to this folder 3. Copy the folder to your folder in the I:\kopp\inbox\CS 222 01 folder Extra Credit – Each of the following is worth 5 points Modify the recursive tree program using one or all of the following ideas:  Modify the thickness of the branches so that as the branchLen gets smaller, the line gets thinner  Modify the color of the branches so that as the branchLen gets very short it is colored like a leaf  Modify the angle used in turning the turtle so that at each branch point the angle is selected at random in some range. For example, choose the angle between 15 and 45 degrees. Play around to see what looks good.  Modify the branchLen recursively so that instead of always subtracting the same amount you subtract a random amount in some range. Add a comment to the top of your program indicating the program it is and store these programs in the same folder as the one above. Be sure to turn I a copy of each program.

(Top Tutor) Studypool Tutor
School: UIUC
Studypool has helped 1,244,100 students
flag Report DMCA

Brown University

1271 Tutors

California Institute of Technology

2131 Tutors

Carnegie Mellon University

982 Tutors

Columbia University

1256 Tutors

Dartmouth University

2113 Tutors

Emory University

2279 Tutors

Harvard University

599 Tutors

Massachusetts Institute of Technology

2319 Tutors

New York University

1645 Tutors

Notre Dam University

1911 Tutors

Oklahoma University

2122 Tutors

Pennsylvania State University

932 Tutors

Princeton University

1211 Tutors

Stanford University

983 Tutors

University of California

1282 Tutors

Oxford University

123 Tutors

Yale University

2325 Tutors