Quantcast
Viewing latest article 34
Browse Latest Browse All 48

Answer by LMeyer for What is a unary type?

Unary is another way of saying "of arity one". A one parameter function is said to be unary, whereas a two parameters function is binary, three is ternary and so forth...

The same principle applies to types. List[A] or Set[A], for example, takes one type A to form a new proper type, whereas Map[A, B] takes two and is said to be a binary type constructor.

On a side note, types which abstract over a type constructor are called higher kinded types (e.g : Monad[F[_]])


Viewing latest article 34
Browse Latest Browse All 48

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>