Capgemini interview question

Differences between Cpp and Java