Update assign4.cpp