MUPL Programs Assignment
Revision as of 05:07, 7 April 2020 by Dennis.cosgrove (talk | contribs)
WARNING: Do NOT attempt until you have completed Parts 1, 2, and 3 of the MUPL Lab.
Motivation
Writing a curried, higher order function as your first MUPL program seems a bit steep. This studio is designed to be done after parts 1, 2, and 3 of the MUPL Lab, but before you attempt to write mupl-map
.
Code to Implement
mupl-double
; racket version for reference (define (racket-double n) (+ n n)) ; mupl-double return a mupl-function which doubles its mupl-int argument (define mupl-double 'not-yet-implemented)
mupl-sum-curry
; racket version for reference (define (racket-sum-curry a) (lambda (b) (+ a b))) ; mupl-sum-curry return a mupl-function which returns a mupl-function which adds the two mupl-function's mupl-int arguments together (define mupl-sum-curry 'not-yet-implemented)
mupl-map-one
; racket version for reference (define (racket-map-one proc) (proc 1)) ; mupl-map-one: return a mupl-function that invoks the mupl-function passed in with the mupl-int argument 1 (define mupl-map-one 'not-yet-implemented)