modified Assignment2