X-Git-Url: http://lambda.jimpryor.net/git/gitweb.cgi?p=lambda.git;a=blobdiff_plain;f=miscellaneous_lambda_challenges_and_advanced_topics.mdwn;h=f05f9fe3f805a6281a58abf55218586cb8428cae;hp=511135a0ffba3a95bc87a449d778dd87f3ca7253;hb=e92858e64c6f61f8ac642550cfcf19c7e14480af;hpb=b3781261c60b4d7cbaee3a48449b3319e6b51f31 diff --git a/miscellaneous_lambda_challenges_and_advanced_topics.mdwn b/miscellaneous_lambda_challenges_and_advanced_topics.mdwn index 511135a0..f05f9fe3 100644 --- a/miscellaneous_lambda_challenges_and_advanced_topics.mdwn +++ b/miscellaneous_lambda_challenges_and_advanced_topics.mdwn @@ -476,23 +476,19 @@ can use. let make_list = \h t. \f z continue_handler abort_handler. f h z (\z. t f z continue_handler abort_handler) abort_handler - now `extract_head` can return the leftmost head directly, using its `abort_handler`: + now `extract_head` should return the leftmost head directly, using its `abort_handler`: let extract_head = \lst larger_computation. lst - ; here's our f (\hd sofar continue_handler abort_handler. abort_handler hd) - ; here's our z junk - ; here's the continue_handler for the leftmost application of f larger_computation - ; here's the abort_handler - larger_computation in + larger_computation 3. To extract tails efficiently, too, it'd be nice to fuse the apparatus developed in these v5 lists with the ideas from the v4 lists, above. But that also is left as an exercise. -5. Implementing (self-balancing) trees +5. **Implementing (self-balancing) trees** more...