HARMAN interview question

C++ question and programing they have asked.