changed output file name for test-medium-2 and added compiler optimizations to Makefile