add listsum example

This commit is contained in:
darkf 2013-10-20 21:52:04 -07:00
parent 3be45c44e5
commit 3b9a5df158
1 changed files with 4 additions and 0 deletions

4
examples/listsum.lamb Normal file
View File

@ -0,0 +1,4 @@
sum([]) -> 0.
sum(x::xs) -> 1 + sum(xs).
putstrln(itos(sum([1, 2, 3]))).