Update pat1007.cpp