Homework 6
Due Date Saturday 2/18 at 10:00 pm
Purpose To design functions that recur on lists and use lists in a big-bang program.
You are required to follow the design recipe for all of the functions you write.
Exercise 1 Design a function that, given a list of strings and a number n, outputs the same list but only with strings less than length n.
Exercise 2 Design a function that, given a list of strings and a number n, outputs whether or not all strings in that list are greater than length n.
Exercise 3 Design a function that, given a list of numbers and a number n, outputs the same list but with n added to every element.
Exercise 4 Design a function that, given a list of numbers and a number n, outputs a list where n is divided by every element in the list. If this would produce an error, the corresponding element in the result list should be the string "DIV0". Note: this exercise requires at least one new data definition not covered by the previous ones.
Exercise 5 Design a simple slide-show program that, given a list of strings, will display them one at a time, advancing when someone clicks the mouse. The program ends when there are no more words to display and then shows a blank screen. Note: the program is given a list of strings. That means the call to big-bang should be wrapped inside a function that takes a list of strings.
Exercise 6 An assignment has a year/month/day due date and a list of exercises. Design a data definition that encapsulates this information.
Exercise 7 Design a function that, given a year/month/day date and a list of assignments, outputs the list of exercises due before that date. (Yes, you may use the append function.)