Answered step by step
Verified Expert Solution
Question
1 Approved Answer
It is a surprising fact in lambda calculus that lists can be expressed as lambda abstractions. Indeed, the list constructor cons can be written as
It is a surprising fact in lambda calculus that lists can be expressed as lambda abstractions. Indeed, the list constructor cons can be written as (x. y. f. f x y). With this definition one can write car as (z. z (x. y. x)) and cdr as (z. z (x. y. y)). Show that using these definitions the usual formulas (car (cons a b)) = a and (cdr (cons a b)) = b are true.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started