Finish homework3.c