Language:EN
Pages: 23
Rating : ⭐⭐⭐⭐⭐
Price: $10.99
Page 1 Preview
especially functional programming conceptsuse one

Especially functional programming conceptsuse one language

CS 3520/6520
Programming Languages

Fall 2021

an object-oriented language

a functional language

lexical scope

recursion

λ-calculus

objects

���

CS 3520/6520 Programming Languages This course is about programming language concepts

Formal prerequisite: CS 3500
Informal prerequisite: more programming experience than that

Grading:
• Weekly homework (55%)
• Two mid-term exams (30%)
• Extended fnal homework (10%)
• Online quizzes (5%)

Watch the videos before class

Take the quiz before class
≥ 60% over semester ⇒ 100%
no late quizzes

Learn concepts by implementinginterpreters

1+2

1��1�

Racket and Plait
Implement interpreters using Plait, a variant of Racket Historically: LispSchemeRacketPlait

PLAI = Programming Languages: Application and Interpretation, a textbook

Preview: Plait Tutorial

http://docs.racket-lang.org/plait/index.html

{ x=0 x>0 0 1
x<0 -1

(cond
[(<x0)-1]
[(=x0)0]
[(>x0)1])

'(123)'(fx)

2��31

`{define{fx}

{+x1}}

(test (area(circle2))
12.56)
(test (area(rectangle34))
12)

33

(define-type Shape
(circle[radius:Number])
(rectangle[width:Number]
[height:Number])
(adjacent[left:Shape]
[right:Shape]))

(define (areas)
(type-case Shapes
[(circler)(*3.14(*rr))]
[(rectanglewh)(*wh)]
[(adjacentlr)(+(areal)
(arear))]))

(define-type Shape
(circle[radius:Number])
(rectangle[width:Number]
[height:Number])
(adjacent[left:Shape]
[right:Shape]))

(define (areas)
(type-case Shapes
[(circler)(*3.14(*rr))]
[(rectanglewh)(*wh)]
[(adjacentlr)(+(areal)
(arear))]))

(define-type Shape
(circle[radius:Number])
(rectangle[width:Number]
[height:Number])
(adjacent[left:Shape]
[right:Shape]))

(define (areas)
(type-case Shapes
[(circler)(*3.14(*rr))]
[(rectanglewh)(*wh)]
[(adjacentlr)(+(areal)
(arear))]))

You are viewing 1/3rd of the document.Purchase the document to get full access instantly

Immediately available after payment
Both online and downloadable
No strings attached
How It Works
Login account
Login Your Account
Place in cart
Add to Cart
send in the money
Make payment
Document download
Download File
img

Uploaded by : Naomi Rogers

PageId: ELIB1825D9