Thanks for the tips Eranga. Here is the New Code. =)
package test;
import java.lang.Math.*;
public class Main
{
public static void main(String[] args)
{
double CurrMoney=5000,TotalMoney,years = 5;
TotalMoney=CurrMoney * (1+(Math.pow((0.05),years)));
System.out.println(TotalMoney);
}
}