I think SVN and Git were built for different processes and software development teams. Generally, SVN is centralized control and Git is de-centralized. Indeed, we can force them to work on the other way around but it is not supposed to be. If you have a team working on the same repository, then SVN is a good choice, but if you are working alone or your team members are following different repositories, then Git is a good choice. However, if you are working alone and you already had a reliable SVN server, then you can see that SVN is very good too.
The OP is asking how to solve the Java HW. So I wish he can find someone to help him with that. Anyway, Java is widely used and probably he can seek for more help on stackoverflow anytime.