I’m sure many other people have something like this, but here’s “Lab 5” from my currently-running PL course:
https://www.brinckerhoff.org/clements/2202-csc430/Labs/lab5.html It introduces church numeral encodings and also this kind of true-false encoding as small programming challenges in Racket. It assumes that you already know how to program in Racket. It doesn’t go deep. John > On Feb 17, 2020, at 9:12 AM, Lawrence Bottorff <borg...@gmail.com> wrote: > > I found these blowing down the sidewalk today > > ; TRUE = λx.λy.x > (define mytrue > (lambda (t) (lambda (f) t))) > > and > > ; FALSE = λx.λy.y > (define myfalse > (lambda (t) (lambda (f) f))) > > Two problems, I don't understand them and AFAICT, they don't work. I traced > them back to this post on stackoverflow. Can anyone get me started here? > > LB > > -- > You received this message because you are subscribed to the Google Groups > "Racket Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to racket-users+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/racket-users/CAFAhFSXjQq2WWei8zvVY38cQmPd9Yb9sd95zCsszWY_aO3xPkA%40mail.gmail.com. -- You received this message because you are subscribed to the Google Groups "Racket Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to racket-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/racket-users/525248ef-03a7-4e88-9ef8-507dd298e433%40mtasv.net.