From 700c5be701e0e8660ae7d1747706d235bdcf0558 Mon Sep 17 00:00:00 2001 From: darkf Date: Sun, 20 Oct 2013 22:45:52 -0700 Subject: [PATCH] refactor examples to use print(x) instead of putstrln(itos(x)) --- examples/factorial.lamb | 2 +- examples/listlength.lamb | 2 +- examples/listsum.lamb | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/factorial.lamb b/examples/factorial.lamb index a63a4ef..c4a2e33 100644 --- a/examples/factorial.lamb +++ b/examples/factorial.lamb @@ -1,4 +1,4 @@ factorial(0) -> 1. factorial(n) -> n * factorial(n - 1). -putstrln(itos(factorial(10))). \ No newline at end of file +print(factorial(10)). \ No newline at end of file diff --git a/examples/listlength.lamb b/examples/listlength.lamb index 4cb0172..5b44050 100644 --- a/examples/listlength.lamb +++ b/examples/listlength.lamb @@ -1,4 +1,4 @@ sum([]) -> 0. sum(x::xs) -> 1 + sum(xs). -putstrln(itos(sum([1, 2, 3]))). \ No newline at end of file +print(sum([1, 2, 3])). \ No newline at end of file diff --git a/examples/listsum.lamb b/examples/listsum.lamb index f171586..97dff4d 100644 --- a/examples/listsum.lamb +++ b/examples/listsum.lamb @@ -1,4 +1,4 @@ sum([]) -> 0. sum(x::xs) -> x + sum(xs). -putstrln(itos(sum([1, 2, 3]))). \ No newline at end of file +print(sum([1, 2, 3])). \ No newline at end of file