Alice @Sasha@witches.town
Suivre

@LottieVixen It's a constructor from an sum data type. You want to have a type for let's say Strings and Int ? Haha, impossible in a strongly typed system where you know the type of each and every value. Let's say you had a container for this type, you stored an object and then some other function read one from this container. How should it use it ? As an Int or as a String ? See ? You can't. So instead, if you wanna consider «a String or an Int» (so the union of the sets corresponding to these two types), you have to build a new type StringOrInt, with to «constructors», kind of «tags» that wrap the value so you know what you have :

N of Int | S of String