ques40.cpp