concept datum structure in category idris

appears as: data structures
Type-Driven Development with Idris

This is an excerpt from Manning's book Type-Driven Development with Idris.

  • Nat—An unbounded unsigned integer type. This is very often used for sizes and indexing of data structures, because they can never be negative. You’ll see much more of Nat later.
  • Views allow you to describe matching on data structures any way you like, with as many patterns as you like, provided you can implement a covering function for the view. As a second example of a view, we’ll implement the merge sort algorithm on Lists.