Commit fb2b1efa authored by Jean-Christophe Filliâtre's avatar Jean-Christophe Filliâtre
Browse files

new theory list.Prefix

parent 8b293634
......@@ -341,6 +341,20 @@ theory Distinct
theory Prefix
use export List
use import int.Int
function prefix (n: int) (l: list 'a) : list 'a =
if n <= 0 then Nil else
match l with
| Nil -> Nil
| Cons x r -> Cons x (prefix (n-1) r)
(** {2 Induction on lists} *)
theory Induction
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment