ⓘ This web page is about the old AlgoSim 2 software. Perhaps you are looking for the new Algosim 3 application?
AlgoSim
Homepage | Screenshots | Gallery of Visualisation | User's Guide | Function Reference | Download | FAQ | Support | Bugs and Solutions | Donate

Reference: drawPolygon

drawPolygon(S) draws the polygon with vertices at the points of S ⊂ R^2 in the current 2D visualization window.

drawPolygon(S, s) draws the polygon with vertices at the points of S ⊂ R^2 using the style (CSS) s.

Example: vertices ≔ {❨1, 1❩, ❨2, 2❩, ❨3, 1❩}
         drawPolygon("vertices")

Compare to: drawLines, e.g. drawLines("vertices"), or drawSet, e.g. drawSet("vertices").