Algebraic Data Types in Elixir
Elixir is a dynamically-typed language. Types in Elixir are checked when a program runs, not when it compiles. If they don’t match up, an exception is thrown. In statically-typed languages, types are checked during compile time. This can help us write code that is correct, understandable, and refactorable. But it also introduces a certain focus on types as the foundation for your application. One interesting concept is to use types to model your business domain.