Add tasks for all the new languages
This commit is contained in:
parent
9dc3c2bb62
commit
bba7bfd280
13208 changed files with 134745 additions and 0 deletions
15
Task/Null-object/EchoLisp/null-object.echolisp
Normal file
15
Task/Null-object/EchoLisp/null-object.echolisp
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
null → null
|
||||
() → null
|
||||
(null? 3) → #f
|
||||
(!null? 4) → #t
|
||||
(null? null) → #t
|
||||
|
||||
;; careful - null is not false :
|
||||
(if null 'OUI 'NON) → OUI
|
||||
|
||||
;; usual usage : recursion on lists until (null? list)
|
||||
(define (f list)
|
||||
(when (!null? list)
|
||||
(write (first list)) (f (rest list))))
|
||||
|
||||
(f '( a b c)) → a b c
|
||||
Loading…
Add table
Add a link
Reference in a new issue