Question: Write a program that will decide whether a customer can borrow a desired amount of money from the bank. Program asks for the following information

Write a program that will decide whether a customer can borrow a desired amount of money from the bank. Program asks for the following information (given in the starter file):

  1. income (float): Amount the customer earns in a year.
  2. credit (float): Amount of money customer wants to borrow.
  3. time (integer): Number of years to pay the money back.

You need to write messages in the console window according to the following criteria:

  1. Customers can borrow money for at least 1 year, at most 5 years.
  2. If the yearly income of the customer is less than 60000 TL, s/he is rejected immediately.
  3. If the yearly income of the customer is more than or equal to 60000 TL, then:
    1. If the loan divided by the number of years is less than half of the customers yearly income, then the customer can take the loan.
    2. Otherwise, s/he is rejected

Sample outputs:

Amount of income per year: 100000

Amount of credit: 80000

Number of years to pay back: 3

You can borrow 80000.0 TL for 3 year(s).

Amount of income per year: 100000

Amount of credit: 80000

Number of years to pay back: 1

You cannot borrow 80000.0 TL for 1 year(s).

Amount of income per year: 80000

Amount of credit: 20000

Number of years to pay back: 1

You can borrow 20000.0 TL for 1 year(s).

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!