problem 2 compiles on mac