re: What the heck is polymorphism? VIEW POST

TOP OF THREAD FULL DISCUSSION
re: Us grey beards call that a union :-) geeksforgeeks.org/difference-struc...
 

Not quite. It's implemented as a tagged union, but the power comes from building a full algebra that makes type composition trivial and very easy to reason about (thus the phrase "algebraic data type"). Their history goes back to the 1970's, so they're not much younger than C and they're older than object oriented programming.

code of conduct - report abuse