
#include "stdio.h"
#include "math.h"
int main() {
double rate, capital;
int year;
printf("Please enter rate, year, capital:n");
scanf("%lf,%d,%lf", &rate, &year, &capital);
// 复利计算公式 deposit = capital * (1 + rate)^year
double deposit = capital*pow(1+rate, year);
printf("deposit=%.3fn", deposit);
return 0;
}
最后
以上就是糊涂荔枝最近收集整理的关于存款利率计算器V1.0 (3分)的全部内容,更多相关存款利率计算器V1.0内容请搜索靠谱客的其他文章。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复