Programming Assignment2, Version1