↧
Answer by Thomas M. DuBuisson for Haskell usage of data type
In surface (Rectangle (Point x1 y1) (Point x2 y2)), we indicate the parameters for Rectangle are of type Point.No. This is your misconception. The compiler knows the type of Rectangle's arguments...
View ArticleAnswer by luqui for Haskell usage of data type
I think you have a misconception here:In surface (Rectangle (Point x1 y1) (Point x2 y2)), we indicate the parameters for Rectangle are of type Point.This does indicate that the parameters are of type...
View ArticleHaskell usage of data type
I am reading making our own types and typeclasses in learn you a haskell.In section Algebraic data types intro I notice:data Point = Point Float Float deriving (Show) data Shape = Circle Point Float |...
View Article
More Pages to Explore .....