Update problem9.cpp