sunildas - SUNIL DAS THOTA 2347946 1. Write a term in the...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
SUNIL DAS THOTA 2347946 1. Write a term in the λ-calculus that represents (S T) ((U,V) W). If needed, you can define some functions using the λ-calculus notation. The above Notation represents a function which takes a function (S T) as Parameter and returns another function ((U,V) W).The parameter itself is a function which takes a value of type S and returns a value of T type. Also, the return value is another function that takes values of U and V as parameters and returns a value of type W. These terms can be represented in λ-calculus as t1 λS.T ----------------1 t2 λU. λV. W ----------------2 Now (S T) ((U,V) W) can be represented in λ-calculus as (λt .( λx.t2)t)t1 (λx.t2)t1 t2 λU. λV. W (from 2) 2. Show the evaluation of the two results given below: * a) and tru tru → λx.λy.x * b) and tru fls λx.λy.y we know and λb. λc.b c fls tru λx. λy.x fls λx. λy.y and tru tru→ ( λb. λc.b c fls)tru tru →( λc.tru c fls)tru tru tru fls (λx. λy.x )tru fls → ( λy tru)fls
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 02/21/2011 for the course CS 542 taught by Professor Dr. thomas during the Spring '10 term at SUNY Buffalo.

Page1 / 5

sunildas - SUNIL DAS THOTA 2347946 1. Write a term in the...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online