Functional Problem Solving (CSC 151 2014F) : EBoards
Primary: [Front Door] [Schedule] - [Academic Honesty] [Disabilities] [Email] - [FAQ] [Teaching & Learning] [Grading] [Rubric] - [Calendar]
Current: [Assignment] [EBoard] [Lab] [Outline] [Reading]
Sections: [Assignments] [EBoards] [Examples] [Handouts] [Labs] [Outlines] [Readings]
Reference: [Setup] [VM] [Errors] - [Functions A-Z] [Functions By Topic] - [Racket] [Scheme Report (R5RS)] [R6RS] [TSPL4]
Related Courses: [Davis (2013F)] [Rebelsky (2014S)] [Weinman (2014F)]
Misc: [Submit Questions] - [SamR] [Glimmer Labs] [CS@Grinnell] [Grinnell] - [Issue Tracker (Course)]
Overview
How do I do other cool things with GIMP/gigls?
There's a huge list of procedures under Help -> Procedure Browser. You can call most of them, although the arguments are a bit strange in some cases.
With your partner:
Most important points
Why do vectors in addition to lists?
Sometimes we want quick access to values; lists are slow, vectors are fast (by index).
Vectors let you change their contents.
Why have lists if we have vectors?
Lists can be expanded easily; vectors can't.
Lists are really easy to recurse over.
Huge number of procedures
Confusing issues
Why would you ever want vector-fill! (particularly given that we
could just use make-vector)?
Mostly there to help you think about recursion over vectors.
How do we make vectors bigger?
You can't.
What's a number vector?
A vector that contains only number.
Laid out in a continuous area of memory. Let's say it starts at location m. Every value takes the same amount of space, s. That means that value i is at position m+si.
vector-fill? answered: We can't redefine things. Hence,
if we want to change them, changing in place is the way to go.vector-sum, just like there are two approaches
to the normal sum. You can use direct recursion or you can use
a helper.