C++ and Java for proj5