Recent Changes - Search:
ECG Home






Fall 2017

Older Courses

Spring 2017

Fall 2016

Spring 2016

Fall 2015

Spring 2015

Fall 2014

Spring 2014

Fall 2013

Spring 2013

Fall 2012

Spring 2012

Fall 2011

Spring 2011

Fall 2010

Spring 2010

Fall 2009

Spring 2009

Fall 2008

Spring 2008

Fall 2007


edit SideBar


Home Assignments Lecture Blog Resources Project Discussion Group

Lecture 39 – Mon May 11

  • went over format for presentation flyer -- see FPFlyer
  • reviewed entire semester, PS1 through PS8 (not including MC eval)
right-click and open in new tab or window to zoom

Lecture 38 – Fri May 8

  • handed back Quiz 2 and went over problems
  • discussed PS9 solution approaches. E.g. for last problem (implementing a new control structure), you could do:

Lecture 37 – Wed May 6 – derived expressions for let->lambda, cond->if, garbage collection, grammars

right-click and open in new tab or window to zoom

Lecture 36 – Mon May 4 – environments, procedure eval, and derived expressions

  • how environments are represented
type into listener, the-global-environment
lookup: (mc-eval 'uml:+ the-global-environment)
add a new binding: (define-variable! 'uml:eq? (list 'primitive eq?) the-global-environment)
more basic lookup: (lookup-variable-value 'uml:+ the-global-environment)
  • procedure definition is just list'ing together the tag 'procedure, the procedure args, the procedure body, and the environment within which its defined
  • we looked at procedure app, including primitive procedures and compound procedures
  • we looked at the environment manipulation procedures, including extending an environment (adding a frame) and looking up variables within the environment. (This is "slow"—linear search through environment frames.)
  • started to talk about derived expressions. Remembered that:
 (let ((x 3))
    (* x y))
is exactly equivalent to (syntactic sugar)
 ((lambda (x) (* x y)) 3)
and the Scheme interpreter dynamically performs this translation each time (yes, this is slow—there is a later version of it that does a form of compilation).

Lecture 35 – Fri May 1 – more on the meta-circular evaluator

  • special forms (if, cond, and, define, lambda) vs. not special forms (+, cons)
  • how mc-eval works for self-evaluating, variables, quoted, assignment/definition, if, and, and lambda
 ;;; MC-Eval input: (uml:lambda (x) (uml:* x x))
 ;;; MC-Eval value: (compound-procedure (x) ((uml:* x x)) <procedure-env>)

Lecture 34 – Wed Apr 29 – introduction to meta-circular evaluator

Mon Apr 27 – Quiz 2

Lecture 33 – Wed Apr 22 – quiz review

right-click and open in new tab or window to zoom

Lecture 32 – Fri Apr 17 – final project discussion

right-click and open in new tab or window to zoom

Lecture 31 – Wed Apr 15

Lectures 28 - 30 -- streams

right-click and open in new tab or window to zoom

Lecture 27 – Mon Apr 6

  • showing how passing in the self procedure works; introduction to PS7 itself

Lecture 26 – Fri Apr 3

  • make-speaker, make-lecturer, make-arrogant-lecturer up until the issue that the self procedure needs to be passed in to get inheritance to work right
right-click and open in new tab or window to zoom

Lecture 25 – Wed Apr 1

  • more environment diagrams including explaining closure of the dispatch procedure that is created by applying make-table from PS6
right-click and open in new tab or window to zoom

Lecture 24 – Mon Mar 30

Lecture 23 – Fri Mar 27

Lecture 22 – Wed Mar 25

  • reviewed generic ops and hash table
  • discussed how make-table produces a closure that includes 4 objects (3 procedures and 1 hash table)
  • walked through function of apply-generic
  • briefly introduced the project

Lecture 21 – Mon Mar 23

  • Generic ops and PS6 -- went through the whole system, sans the apply-generic procedure

Lecture 20 – Fri Mar 13

  • Scheme numbers—exact and inexact
  • More about eq?, eqv?, and equal?
  • Projects discussion—look at last semester's work, start thinking about what you are interested in
  • Handed back quizzes and PS4
  • Assigned mid-term grades; the four problem sets are worth 1/3 of the grade, and the quiz is worth 2/3s.

Lecture 19 – Wed Mar 11

  • Discussion of why studying Programming Languages is important, with showing of slides from Dr. Kathleen Fisher's talk about SIGPLAN (ACM's Special Interest Group on Programming Languages)
  • Material for PS5: how to add simplification to make-sum expression generator; how the differentiator deriv works

Lecture 18 – Mon Mar 9

Lecture 17 – Fri Mar 6

  • went over list cons car cdr examples from Symbolic Differentiation handout
  • talked about FP vs. OO and value of no side-effects
  • eval forces evaluation and quote prevents it. They are like opposites.
  • dove into deriv routine a bit

Lecture 16 – Wed Mar 4

Symbolic data and differentiation

Lecture 15 – Mon Mar 2

  • snow day

Lecture 14 – Fri Feb 27

  • Quiz 1

Lecture 13 – Wed Feb 25

  • Making Music from Fibonacci
  • make-rat, numer, denom
  • abstraction barrier and similarity to information hiding/encapsulation; mutator/accessor
  • closures

Lecture 12 – Mon Feb 23

  • quiz review

Lecture 11 – Fri Feb 20

  • Quiz 1 will be Fri Feb 27
  • Henderson picture language!

Lecture 10 – Wed Feb 18

  • fun with accumulate—especially, accumulate-tree

(right-click and open in new window to enlarge)
  • e.g., how to scale the leaves returning a tree, how to count the number of even leaves

Lecture 9 – Tue Feb 17

  • map, filter, accumulate

Lecture 8 – Fri Feb 13

Lecture 7 – Wed Feb 11

  • length again
  • reverse
  • issue with inner defines: don't work in Advanced Student with Lambda, but do work in Module

Lecture 6 – Mon Feb 9

  • cons, car, cdr, list, quote
  • length (recursive and iterative)
  • nth

Lecture 5 – Fri Feb 6

  • sum, sum-cubes, and pi-sum example of passing procs as args into procs
  • "1st class procedures" (though we haven't done procedures producing procedures yet)
  • let and lambda

Lecture 4 – Wed Feb 4

  • fibonacci and its recursive and iterative forms
  • exponential growth (in space) based on golden ratio
  • more discussion of how tail recursion implements a loop
  • which other languages have tail recursion? need to find out.
  • teaser of passing procedures as args to procedures

Lecture 3 – Monday Feb 2

  • PS2
  • iterative vs. recursive processes, produced by recursive procedures
  • went over two implementation of factorial (from book) and did first problem from PS2 in class
  • discussed tail recursion, and how it is "syntactic sugar" for looping constructs such as for and while
  • our defn of tail-recursion: when last expression of a procedure evaluates directly to a recursive call of the same procedure. Also, all state of the procedure is captured in its arguments
  • mystery procedure defined in terms of lambda -- if it used (define (mystery a b) ... ), then maybe stepper would work. What is the binding for mystery within the lambda before mystery itself is defined?

Lecture 2 – Friday Jan 30

Lecture 1 – Monday Jan 26

  • what is functional programming
  • class structure/grading/project
  • lambda and define
Edit - History - Print - Recent Changes - Search
Page last modified on May 12, 2009, at 08:03 PM