include_template( 'topper.html' ); ?> CS 3304 semester(); ?> Homework Assignment 5 include_template( 'page-start.html' ); ?>
Note: The following instructions are repeated from the Homework Dates/Guidelines page:
Your solutions for each homework assignment must be prepared with a word processor (e.g., LaTeX or Word), and are due at the beginning of class on the due date specified unless otherwise noted on the assignment itself.
Note that all homework problems taken from the text are in the Problem Sets. Do not turn in solutions to Review Questions by mistake!
Complete each of the following problems:
list-head
:
(list-head list k)
Returns a newly allocated list consisting of the first k elements of list. K must not be greater than the length of list.
Name your function my-list-head
, since
list-head
is already provided as a standard
operation in Scheme (you may not use list-head
,
list-tail
, or sublist
in your solution).
include_template( 'page-end.html' ); ?>