Question

Can you write a simple code in Mathematica software to calculate in how many years you...

Can you write a simple code in Mathematica software to calculate in how many years you will repay a debt at 6%.

A=2000, I=6%, M.P. = 200

Homework Answers

Answer #1

Java Program:

public class NumOfMonths {
public static void main(String args[])
{
double A=2000;
double I=6;
double MP=200;
double i= I/12/100;
//N = −log(1−iA/P) / log(1+i)
double t1=-Math.log(1-i*A/MP);
double t2=Math.log(1+i);
double years =t1/t2;
System.out.println(" You can take out $"+MP+" a month for "+Math.ceil(years)+" months");
}
  
}

Output:

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
How many ways are there that you can write code for a Servlet?
How many ways are there that you can write code for a Servlet?
Kristin and Ricardo work for a software firm. Kristin can write 12 batches of code a...
Kristin and Ricardo work for a software firm. Kristin can write 12 batches of code a day, or answer 18 help-line calls a day. Ricardo can write twelve batches of code a day, or answer twelve help-line calls Who has the comparative advantage in writing batches of code? In answering help-line calls? If you were the manager of these two people, explain how would you direct them to spend their time. What do managers usually do when employees perform better...
Write a SQL code that finds how many days away from thanksgiving. The code should work...
Write a SQL code that finds how many days away from thanksgiving. The code should work in any month in this year 2020. write a code to find the oldest person from a table has an age column. NOTE: please use ssms to write the code with a screenshot of the output.
**C code only In this part, you will write a simple user-defined function that prints a...
**C code only In this part, you will write a simple user-defined function that prints a message. This function does not require any parameters or return value. The purpose is simply to get you started writing functions.Open repl project Lab: User-Defined Functions 1. Write a program that calls a function. This function should do the following: 1.Ask the user their name 2. Print a "hello" message that includes the user's name Example output: Please enter your name: ​Mat Hello, Mat!...
can you explain how do I calculate or use significant numbers? ex like how many in...
can you explain how do I calculate or use significant numbers? ex like how many in 100 compare in 1.8970
Write the message, “Hello World” in ASCII code. [D: Decimal, B: Binary] can you explain how...
Write the message, “Hello World” in ASCII code. [D: Decimal, B: Binary] can you explain how to go about this really trying to understand
When you write code, how do you know that you need to use value or reference?...
When you write code, how do you know that you need to use value or reference? Please show with an example. I know reference is two way communication but it is not clear to me. Thanks
how many years are needed for $55 to yield a 8.8% in interest at the simple...
how many years are needed for $55 to yield a 8.8% in interest at the simple interest rate of 8%
Please code C# 7. Write a program that can calculate the sum of all numbers between...
Please code C# 7. Write a program that can calculate the sum of all numbers between 1 and 1000 inclusive (including 1 and 1000)
how do you calculate the percent of EBIT over many years? such as five or more...
how do you calculate the percent of EBIT over many years? such as five or more years as a percent.