dg icon indicating copy to clipboard operation
dg copied to clipboard

Misguide in documentation (return values)

Open ceremcem opened this issue 6 years ago • 3 comments

There is a misguide in documentation:

image

This function is obviously expected to return 4 (as the first line in the screenshot says) but the function name (definitely_not_4) is misleading:

definitely_not_4 = x ->
    x + 2
    4

print <|  definitely_not_4 40  #=> not 4

and it definitely returns 4:

image

...in contrast with the function name.

ceremcem avatar Jul 22 '17 17:07 ceremcem

I think that was supposed to be humor...

refi64 avatar Jul 23 '17 01:07 refi64

...a little bit too much humor for a documentation. I just got it :rofl:

ceremcem avatar Feb 24 '19 06:02 ceremcem

Yeah, the tutorial is supposed to be a bit tongue-in-cheek, as the fake O'Reilly cover might suggest. Kind of hints that the project is not particularly serious, no? (Probably didn't age well, though.)

pyos avatar Feb 24 '19 16:02 pyos