1 Matching Annotations
- Dec 2015
-
math.mit.edu math.mit.eduCT4S.pdf1
-
Since ducks can both swim and fly, each duck is found twice inC, once labeled as aflyer and once labeled as a swimmer. The typesAandBare kept disjoint inC, whichjustifies the name “disjoint union.”
The disjoint union reminds me of algebraic datatypes in functional programming languages, whereas a set-theoretic union is more like a union in CS: the union has no label associated with it, so additional computation (or errors) may arise due to a lack of ready information about elements in the union.
-