Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
19
Task/Pentagram/Haskell/pentagram.hs
Normal file
19
Task/Pentagram/Haskell/pentagram.hs
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
-- Extract the vertices of a pentagon, re-ordering them so that drawing lines
|
||||
-- from one to the next forms a pentagram. Set the line's thickness and its
|
||||
-- colour, as well as the fill and background colours. Make the background a
|
||||
-- bit larger than the pentagram.
|
||||
|
||||
import Diagrams.Prelude
|
||||
import Diagrams.Backend.SVG.CmdLine
|
||||
|
||||
pentagram = let [a, b, c, d, e] = trailVertices $ pentagon 1
|
||||
in [a, c, e, b, d]
|
||||
# fromVertices
|
||||
# closeTrail
|
||||
# strokeTrail
|
||||
# lw ultraThick
|
||||
# fc springgreen
|
||||
# lc blue
|
||||
# bgFrame 0.2 bisque
|
||||
|
||||
main = mainWith (pentagram :: Diagram B)
|
||||
Loading…
Add table
Add a link
Reference in a new issue