#C语言写一个等额本息房贷计算器
#include <iostream>
#include<math.h>
using namespace std;
int main()
{double Sum_Loan;double Sum_Loan_Length;double Loan_Rate;double Month_Supply;double Month_Rate;cout << endl << endl;cout << endl << endl;cout << " ---------------等额本息法房贷计算器----------------- "<<endl<<endl;cout << " V1.0 20220617 " << endl;cout << endl<<endl;cout << " Business Loan(万) : " ;cin >> Sum_Loan;Sum_Loan *= 10000;cout << " Loan Sum Month Length : ";cin >> Sum_Loan_Length;cout << " Loan Rate : ";cin >> Loan_Rate;Month_Rate = Loan_Rate / 12;Month_Supply = (Month_Rate)*pow((1 + Month_Rate), Sum_Loan_Length) * Sum_Loan / (pow((1 + Month_Rate), Sum_Loan_Length) - 1);cout << endl << endl;cout << " OutCome :" << endl;cout << " Your Business Loan(万) : " << Sum_Loan/10000 << endl;cout << " Loan Sum Month Length : " << Sum_Loan_Length << endl;cout << " Loan Rate : " << Loan_Rate << endl;cout << " Month Supply : " << Month_Supply << endl;cout << " Sum Profit(万) : " << (Month_Supply* Sum_Loan_Length- Sum_Loan)/10000 << endl;system("Pause");
}
房贷计算器下载地址:
链接:https://pan.baidu.com/s/1kHgKiDj7aymeroTucWuhwQ
提取码:s7gt