Approximate overview
Events
Process
Where did the names of the computers come from?
Famous dead computer scientists.
Before ITS got even more paranoid, you used to be able to connect to each computer on the Web and see a bio of the computer scientist.
Reminder to self: Perhaps that info belongs on www.cs.grinnell.edu.
How do we use test-true for procedures that do not return a Boolean?
Consider trim. You can write
(test-true "no spaces" (equal? (trim "Hello") "Hello"))
What do you mean “by magic numbers like 48”?
;;; (digit->num ch) -> integer?
;;; ch : character? (in the range #\0 to #\9)
;;; Convert a character digit to the corresponding integer.
(define digit->num
(lambda (digit)
(- (char->integer digit) 48)))
This is more readable as
(define collation-number-for-digits 48)
(define digit->num
(lambda (digit)
(- (char->integer digit) collation-number-for-digits)))
Or
(define digit->num
(lambda (digit)
(- (char->integer digit) (char->integer #\0))))
That suggests that we’re offsetting from zero, which should give us the value of the digit (if they are stored in reasonable order in the collating sequence).
It also works if we switch collating sequences.
Don’t spend too much time on the “other list procedures”.
It’s nice to see some of you diagramming out what should happen in the exercise 3 algorithm.
Eamon says, “Wow, that’s not how I would have solved problem 3. This is a very different way of thinking.” Sam says, “Yes, that’s the point; we’re trying to stretch their brains.”
Problem 6 is optional.
Yes, you have to finish this outside of class. But you can have until Monday. Please try to find a time to meet with your partners.
Prof. J says, “Sam may be terrifying, but students should still ask questions and not push forward on their own.”