Search code examples
pythonwindowspolygonpoints

Python, generating a ten Point polygon


I am attempting to generate a polygon with Points. I am using Python 3.4 on Windows 7. I would like to know where my error is in this line of code.

leftEar = Polygon(Point(158,218), Point(160,208), Point(166,197), Point(174,186), Point(183,180), Point(190,179), Point(195,184), Point(197,191), Point(193,199), Point(184,210))

leftEar.setFill("blue")

leftEar.setOutline("black")

LeftEar.draw(win)

These points were all gathered from within a graphic window using another line of code provided to me by another person. Posting that into this window is nearly impossible, even when I hand type it in using only the space bar to obtain the indentations.


Solution

  • You have capitalised the 'L' of LeftEar in the final line.