problems from the function chapter