Java program to calculate Compound Interest