X-Git-Url: http://lambda.jimpryor.net/git/gitweb.cgi?p=lambda.git;a=blobdiff_plain;f=exercises%2Fassignment4_hint.mdwn;h=666b46036e2fe7e2ff1ec3dbc58505923faa18ae;hp=339bb1628d8302b58abd3a5e78f4ca7094194dc5;hb=cff9857e52ac59c4905efeb80fcf8a91c2fd1ed8;hpb=4e92456d3dda2c68b8ff0151a0d01fa0750c1971 diff --git a/exercises/assignment4_hint.mdwn b/exercises/assignment4_hint.mdwn index 339bb162..666b4603 100644 --- a/exercises/assignment4_hint.mdwn +++ b/exercises/assignment4_hint.mdwn @@ -67,6 +67,11 @@ where `X1` happens also to be the lambda term that is the head of `Î¾1`; and `X2` happens also to be the lambda term that is the head of `Î¾2`. +* Where we have `H` in `X1` (the head of `Î¾1`), there we could just use the bound variable `u`, right? Similarly for `G` we could just use the bound variable `v`, right? And similarly for `X2` (the head of `Î¾2`). So: + + Î¾1 â¡ (\u v. h (X1 u v) (X2 u v)) H G + Î¾2 â¡ (\u v. g (X1 u v) (X2 u v)) H G + * Can you solve it yet? * Don't bring in `Y` or any other already-familiar fixed point combinator; that's a false path. You don't need it. @@ -79,8 +84,6 @@ * `H` is `X1` and `G` is `X2`. -* Also, where we have `H` in `X1` (the head of `Î¾1`), there we could just use the bound variable `u`, right? Similarly for `G` we could just use the bound variable `v`, right? And similarly for `X2` (the head of `Î¾2`). - * Now can you figure out how to get rid of the explicit self-referencing whereby `X1` contains the free variable `X1`, meant to refer to the lambda abstract that contains it? If `X1` is just `H`, also known inside the body of `X1` as `u`, we could just write `Î¾1` like this, right: Î¾1 â¡ (\u v. h (u u v) (X2 u v)) H G