程序代写代做代考 1. Create a type representing a border style (for use in layout out a document, for example). The border style will either be invisible, or it will have a color, width, and line style. The colors are red, green, blue, and black. The widths are thin, medium, and thick. The line styles are solid, dashed, dotted, and wavy.

1. Create a type representing a border style (for use in layout out a document, for example). The border style will either be invisible, or it will have a color, width, and line style. The colors are red, green, blue, and black. The widths are thin, medium, and thick. The line styles are solid, dashed, dotted, and wavy.
You will probably want to define several other types to use in your border style definition. Do not use String, Char, or any number types.
As a demonstration, define a constant thin_red of your border style type, representing a red, thin, solid border.
Write a function that returns true if its argument is any border style with color green and line-style wavy.
2. Using this definition:
data Point = Point { x :: Double, y :: Double, z :: Double } deriving (Show, Eq)
Write a function giving the distance between two points.
dist :: Point -> Point -> Double
Write a function that projects a point to the X-Y plane (with the same X and Y coordinates, but with Z coordinate 0).
projXY :: Point -> Point