Skip to content

Instantly share code, notes, and snippets.

@siddhartha-gadgil
Created March 22, 2014 09:12
Show Gist options
  • Select an option

  • Save siddhartha-gadgil/9703604 to your computer and use it in GitHub Desktop.

Select an option

Save siddhartha-gadgil/9703604 to your computer and use it in GitHub Desktop.
_contains_ : {A : Set} → List A → (A → Bool) → Bool
[] contains _ = false
(x :: xs) contains p = (p x) || (xs contains p)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment