X-Git-Url: http://lambda.jimpryor.net/git/gitweb.cgi?p=lambda.git;a=blobdiff_plain;f=exercises%2Fassignment3_answers.mdwn;h=6aa5d7503467a77a8359fdd7df23ba1c39628f71;hp=7530534f3c4e086c6260aaaface0b1b6b4126809;hb=8950982eae04ec4ca70862e23122256b526b591b;hpb=b78913233fb5db8dc92cf8359d823c518a257a84 diff --git a/exercises/assignment3_answers.mdwn b/exercises/assignment3_answers.mdwn index 7530534f..6aa5d750 100644 --- a/exercises/assignment3_answers.mdwn +++ b/exercises/assignment3_answers.mdwn @@ -238,23 +238,6 @@ Reduce the following forms, if possible: Using the mapping specified in this week's notes, translate the following lambda terms into combinatory logic: - -Let's say that for any lambda term T, [T] is the equivalent Combinatory Logic term. Then we define the [.] mapping as follows. - - 1. [a] = a - 2. [(\aX)] = @a[X] - 3. [(XY)] = ([X][Y]) - -Wait, what is that @a ... business? Well, that's another operation on (a variable and) a CL expression, that we can define like this: - - 4. @aa = I - 5. @aX = KX if a is not in X - 6. @a(Xa) = X if a is not in X - 7. @a(XY) = S(@aX)(@aY) - - - -
  1. [\x x] = @x x = I
  2. [\x y. x] = @x [\y. x] = @x. (@y x) = @x (Kx) = S (@x K) (@x x) = S (KK) I; in general expressions of this form S(KM)I will behave just like M for any expression M