AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |
Back to Blog
Sidenotes 1.1.11/27/2024 ![]() The resulting indentations display clearly the structure of the expression. It is a little disturbing, though, that the suggestion given for readability-the tab-based prettyprinting-is given with so little self-awareness: The explanation is quite serviceable, and the reasons in favor of it are cogent enough. Parentheses SyntaxĪfter this, the author begin tackling Lisp’s infamous prefix notation. They have tremendous trouble when their math classes start touching on algebra and functions and evaluation. I don’t think I’ve ever seen any youngster express things in a functional or recursive form very naturally. ![]() Iteration is more natural and intuitive in a sense. Think of a child doing chores: you don’t tell her to clean each part of the living room until it’s clean, you tell her to clean first the cat throwup over in the corner, then take care of the overfull garbage bag, then vacuum, then sweep and finally you can go play. Evaluation is kind of a do-while loop: ‘while the result of evaluation is different from the evaluated thing, keep evaluating.’ One expects a fixed number of steps. ![]() It’s something of an unobvious idea-when you think about it, it’s not the same as equaling, but it doesn’t exactly seem like the normal idea of an algorithm. 1 evaluates to 1, 1 + 1 evaluates to 2, 1 + 1 / 2 evaluates to 2 / 2 which evaluates to 2, and so on. Chapter 1.1 mingles syntax with the basic functional/applicative idea of ‘evaluating and substituting’.
0 Comments
Read More
Leave a Reply. |