Update prog4.cpp

added pagereplace func to menu