CS 370 solutions