Functional Problem Solving (CSC 151 2015F) : EBoards
Primary: [Front Door] [Schedule] - [Academic Honesty] [Disabilities] [Email] - [FAQ] [Teaching & Learning] [Grading] [Taking Notes] [Rubric] [Remote Access]
Current: [Assignment] [EBoard] [Lab] [Outline] [Reading]
Sections: [Assignments] [EBoards] [Labs] [Outlines] [Readings] - [Examples] [Handouts]
Reference: [Setup] [VM] [Errors] - [Functions A-Z] [Functions By Topic] - [Racket] [Scheme Report (R5RS)] [R6RS] [TSPL4]
Related Courses: [Curtsinger (2015F)] [Davis (2013F)] [Rebelsky (2015S)] [Weinman (2014F)]
Misc: [Submit Questions] - [SamR] [Glimmer Labs] [CS@Grinnell] [Grinnell] - [Issue Tracker (Course)]
Overview
Do you have any observations after helping people with Part C?
Remember that when you decide to split the region, you have to recurse twice - either for the left half and right half, or for the top half and bottom half.
Remember that
left,top,width, andheightall have to be integers. In some cases, you won't be able to divide exactly.
What angle did you use for the swirly one?
I think I used (/ pi 32)..
The original "painting" was made by selecting left:100, top: 50, width: 200, height:260.
When replacing, I used left: 110, top: 60, width: 180, height: 240, which I think preserved the aspect ratio of the image.
map, for-each, repeat, and recursionmap:
(map + (list 1 2 3) (list 4 5 6))
For multiple lists, it takes the ith element of each input list and
then applies the function. for-each:
map, which shoves the results together into
a list).repeat:
recursion:
If you go from a list to a list of the same length: map
If you do things mostly for side effects: for-each or repeat
General case: recursion