function calc(sum,percent,dayCount) {
percent = Number(percent);
sum = Number(sum);
dayCount = Number(dayCount);
return sum * Math.pow(1 + percent / 100, dayCount);
}
$("#calcButton").click(function() {
$('#result').html(calc(
$('#sum').val(),
$('#percent').val(),
$('#day').val()
).toFixed(2));
});