cpp ex2 response

added