git @ Cat's Eye Technologies Robin / cb94157
Fix indentation and version number. Chris Pressey 1 year, 5 months ago
2 changed file(s) with 8 addition(s) and 8 deletion(s). Raw diff Collapse all Expand all
00 ;''
1 Deadfish ( http://esolangs.org/wiki/Deadfish ) implemented in Robin 0.9
1 Deadfish ( http://esolangs.org/wiki/Deadfish ) implemented in Robin 0.8
22 ''
33
44 (require itoa) (require bind-vals)
66 `list?` evaluates its argument, then evaluates to `#t` if it is a list,
77 `#f` otherwise.
88
9 | (list? (literal (a b)))
9 | (list? (literal (a b)))
1010 = #t
1111
12 | (list? (literal (a b c d e f)))
12 | (list? (literal (a b c d e f)))
1313 = #t
1414
15 | (list? (prepend 4 (prepend 5 ())))
15 | (list? (prepend 4 (prepend 5 ())))
1616 = #t
1717
1818 The empty list is a list.
1919
20 | (list? ())
20 | (list? ())
2121 = #t
2222
2323 Symbols are not lists.
2424
25 | (list? (literal a))
25 | (list? (literal a))
2626 = #f
2727
2828 The argument to `list?` may (naturally) be any type, but there must be
2929 exactly one argument.
3030
31 | (list? (prepend 4 ()) (prepend 6 ()))
31 | (list? (prepend 4 ()) (prepend 6 ()))
3232 ? abort (illegal-arguments ((prepend 4 ()) (prepend 6 ())))
3333
34 | (list?)
34 | (list?)
3535 ? abort (illegal-arguments ())
3636
3737 '<<SPEC'