added problem 10, which segfaults when compiled with -O3, but gets the right answer slowly without optimization