Let's imagine we are selling car insurance. Before we try selling it to a customer,
we try to determine if the customer is a valid potential customer for our company by checking the customer's sex and age.
A simple customer model:
Next we want to define an exclusion list (table) so that if a customer matches any row
in the exclusion list the customer is cannot buy our car insurance.
Because of type-inference and partial application, the exclusion list is flexible yet
easy to understand.
Finally, we define a function that uses the exclusion list (a table) to split the customers into two buckets: potential and denied customers.
To wrap up, let's define some customers and see if they are any potential customers
for our car insurance amongst them:
This modified text is an extract of the original Stack Overflow Documentation created by following contributors and released under CC BY-SA 3.0