Practice and apply:
·Lists
·Loops
·User-defined functions
The task
Create a program that draws an attractive “string art” style design.Your program must produce at least three collections of points, with each collection stored as 2-integer tuples contained in a list. Two of the collections must have at least 10()points each, and the other collection must have at least 3 points.
Then, using for loops, connect the points of each list with the points of another list so that all points have at least one connection to point(s) in another collection.
Requirements
Your program must use user-defined functions in two ways.
1.The collections of points must be created in a value-returning function().The value returned is a list of points.The returned value will be assigned to a variable in the main program. Your collection-generating function may or may not have parameters; that’s up to you.Here are a couple of example statements in the main program that includes a call to a function that creates and returns a list of points:
leftSet = makePoints()
reightSet = makeCirclePoints( (100,46),50,10 )
2.The points created in the functions cannot be comply literals; they have to be created by a calculation in a loop or by having the turtle walk a path and using xcor() and ycor().
3.The lie connecting two points must actually be drawn using a function.Here is the function stub for that function:
def connect(p1,p2,lColor):
return