Well, it kinda "makes sense"...
#programming
@fuxoft So (println(+)) is what, 0?
@filiph Yes, it is!
@fuxoft The first Racket user I know 👏
@segedacz Not yet "user". We'll see about that. Do you know of something similar with similarly excellent documentation?
@fuxoft I cannot compare, but the new Erlang documentation is enough for me.
@segedacz How "new" is that? I've worked in Erlang about 5 years ago and the docs weren't exactly a walk in the park.
@AverageDog @filiph That's a great sentence!
@AverageDog @fuxoft so wait, is it possible to evaluate any operand and function this way? What's (sin) and (cos) then? What's (/)? Do operands and functions need to deal with null arguments? Do they get to provide defaults?
@filiph @fuxoft
If a function has a neutral element, then applying it to zero arguments will return it. If a function has no neutral element, calling it with zero arguments is an error.
E.g.:
(sin) ==> error
(-) ==> error
(- 1) ==> -1
(- 1 1) ==> 0
(- 10 2 3) ==> 5
#scheme #lisp #functions
@fuxoft New is alias for new skin/design. 😀 Content is probably the same.
- replies
- 0
- announces
- 0
- likes
- 0