Capgemini interview question

difference between the java and c++