An m-star of order n consists of m line segments of equal lengths that begin at a common point, pass through the vertices of an m-sided regular polygon centered at the point, and end at the center of...



An m-star of order n consists of m line segments of equal lengths that begin at a common point, pass through the vertices of an m-sided regular polygon centered at the point, and end at the center of an m-star of order n – 1 whose line segments are shorter than those in the star of order n. An m-star of order 0 is empty. Note that m must be 3 or greater.






For example, a 5-star of order 3 appears as follows:





Write a recursive program that creates an m-star of order n. Continue the recursion until either a maximum number of recursive levels is reached or the line segments become too small. You can choose a fixed value of m, but for more of a challenge, let the user specify m.



May 18, 2022
SOLUTION.PDF

Get Answer To This Question

Submit New Assignment

Copy and Paste Your Assignment Here