The "basics lab" has you working through a sequence of basic exercises in Scheme.
(Apple Study by ellasdad, CC-BY @ Flickr.)
CMPSC 220 - Allegheny College - Spring 2010
Agile software development tends to be more people and process oriented than traditional top-down methods.
The "basics lab" has you working through a sequence of basic exercises in Scheme.
(Apple Study by ellasdad, CC-BY @ Flickr.)
An important part of this laboratory is to give you a chance to write excellent code. That is code that is developed using a sound method, well commented, well tested, and properly styled. The exercises themselves are not meant to be terribly hard; that is intentional. However, it is challenging to slow down and practice the art and craft of programming. See the page on coding style to see what I am hoping you will practice in this lab.
You will also want to read the preface and chapter 2 of HtDP.
'German, your function might return 'GutenMorgen.'inclusive or 'exclusive. The function should return a function that, when invoked, consumes a single number and returns a boolean. In short, write a function that builds the functions you just wrote. Re-implement your answers to #10 using your new "function-builder." (Only dedicate time to this problem if you get done with everything else, and you want to explore a bit.)(+ (10) 20) (10 + 20) (+ +)
(define (f 1) (+ x 10)) (define (g x) + x 10) (define h(x) (+ x 10))
(+ 5 (/ 1 0)) (sin 10 20) (somef 10)
These exercises are for mastery of foundational skills.
If you feel you could reproduce this work from scratch, on your own, then you have achieved some mastery of the material presented here.
If you need more practice, see me; I can develop another set of practice problems. Or, perhaps go off and try working the problems again.
If you have written excellent code, understand it, and have the time, you might explore the language further by reading some of the resources I've linked to... perhaps by reading ahead in HtDP, or looking at TSPL or Fixnum Days.
Note many of the exercises in this lab come here or here or here (PDF). (Just acknowledging my sources/places I stole from.)
I had 4 goals in assigning this first laboratory.
If you would please rate this first laboratory based on these goals, and provide whatever feedback you feel is necessary to improve this lab in the future, that would be excellent.
This work is licensed under a CC BY-SA 3.0 License.