1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
bekas [8.4K]
3 years ago
5

This assignment is to read from an input file and process the data for a group of people. Your program calculates the interest a

nd print the details to the monitor, refer to the sample below. Terminate the program when the end of file is reached. In this assignment there is no need to verify data.
Write a Java program that accepts an amount of money on deposit and a number of years it has been on deposit. It will determine the interest to be paid on the deposit based on the following schedule:
Time on Deposit Interest Rate
>= 5 years 4.5%
Less than 5 and >=4 years 4%
Less than 4 and >=3 years 3.5%
Less than 3 and >=2 years 2.5%
Less than 2 and >=1 years 2%
Less than 1 year 1.5%
The program will use the entered code to determine number of times compound interest is calculated and paid per year.
Code Number of times calculated
A 4
B 2
C 1
D 12
E 365
Compute the interest using the following formula:
A = P(1+ r/n)^nt
P = principal amount (the initial amount you borrow or deposit).
r = annual rate of interest (as a decimal).
t = number of years the amount is deposited or borrowed for.
A = amount of money accumulated after n years, including interest.
n = number of times the interest is compounded per year.
Example:
An amount of $1,500.00 is deposited in a bank paying an annual interest rate of 4.3%, compounded quarterly. What is the balance after 6 years?
Solution :
Using the compound interest formula, where P - 1500,- 4.3/100 - 0.043, n = 4, t - 6.
Therefore,
Calculation A - 1500 (1+0.043/4)(4.6)
So, the balance after 6 years is approximately $1,938.84.
Display the original deposit, the interest earned and the new Balance (with interested added to the deposit).
Display the original deposit, the interest earned and the new Balance (with interested added to the deposit).
Your program will prompt user for the name of input file and will process all the data in the file.
Refer to the samples below for input file and output format.
Requirements:
• Prompt user for file names.
• include minimum of 4 Methods, more is OK.
• Use good variable names.
Input file format:
Name
Amount deposited Years Code
Input file sample:
Joseph Cardian III
1800 6
Nancy Brown
6780 10
Sample output 1
Program Number 1
Joe Blake
Computer Science 3
Enter File name: assign3.txt
Name Years Deposit Amount Interest Earned Total
Joseph Kardian III 6 $1500.00 $461.99 $1961.99
Nancy Brown 10 $6780.00 $3835.32 $10615.32
Thank you for using interest calculation program. Have a nice day.
Sample output 2
Program Number 1
Joe Blake
Computer Science 3
Enter File name: abc.txt Could not open file. Program terminated.
Sample output 3
Program Number 1
Joe Blake
Computer Science 3
Enter File name: blank.txt
There was no data in the file. Program terminated.
Computers and Technology
1 answer:
nignag [31]3 years ago
7 0

Answer:

the way of for 3

Explanation:

You might be interested in
Write a flowchart and C code for a program that does the following: Uses a do...while loop. Prints the numbers from 1 to 10 with
emmasim [6.3K]

Answer:

create the integer variable and initialize it to one, with the do statement, increment the variable by one and print it, then the while statement checks if the variable is less than or equal to 10.

#include <iostream>

using namespace std;

int main(){

   int i = 1;

   do {

       cout<< i << "\n";

       i++;

   }

   while (i <= 10);

}

Explanation:

The C++ source code initializes the integer variable i to one and increments and print the value if the value is less than or equal to ten. The do-while statement executes a block of code before the condition is implemented.

4 0
3 years ago
If parties in a contract are not ____, the contract can be canceled.
Anastasy [175]
Agreed to all the terms mentioned in the contract
5 0
3 years ago
" _____ is a measure of the amount of information that can travel from a user to the Internet in a given amount of time."
Ainat [17]

Answer:

The answer is Upload bandwidth

Explanation:

Bandwidth refers to the highest transfer rate of data on an internet connection or network.

Upload bandwidth is the amount of data that moves from a computer to the internet or a network within a given amount of time. Documents, music files, video files, software and so on can be uploaded to the internet or a network.

6 0
3 years ago
Which game title went on to become the highest selling unbundled cartridge game?
alexandr402 [8]

Answer:

Tetris

Explanation:

On June 6, 1984, the first version of Tetris was unveiled and quickly took the world by storm. While Tetris has appeared on every major gaming platform from the Commodore 64 to the iPhone, it arguably gained its greatest notoriety as the cartridge game bundled with the original Nintendo Game Boy.

5 0
2 years ago
A chief Information Security Officer (CISO) is performing a BIA for the organization in case of a natural disaster. Which of the
nataly862011 [7]

Answer:

The correct answer is option (D) Identify the impact on safety of the property

Explanation:

Solution

In every Business Impact Analysis, the first and the most important step is for the CISO is to identify and estimate the impact of the aftereffects on the business and property of an organization that may be occurred from the disaster.

Physical security is very important, but it is not noticed by most organizations. It is important if you do not want anyone to take  away your information or destroy it, in case of natural calamity. the reason could be that, the intruder is  doing it for his personal achievement, financial gain,or seeking revenge or when one is taken unaware and becomes a target. If this security is not maintained properly all the safety measures will not be useful once the attacker gets through by gaining physical access.

Example of property can be software, equipment, facilities, company’s assets.

4 0
3 years ago
Other questions:
  • video-sharing sotes such as youtube and vimeo provide a place to post short videos called clips true or false?
    5·1 answer
  • Typohunting is registering a domain name that is similar to a trademark or domain name but that is slightly misspelled in hopes
    5·1 answer
  • Hey does anybody know how to delete history on a school-issued chrome book, I tried to delete it but it won't let you clear your
    7·1 answer
  • Paul has been working long hours. He is tired and distracted by family issues,
    10·1 answer
  • A _____ is a number that summarizes an encrypted information. digital certificate hash function message digest hash algorithm
    8·1 answer
  • Create the following new exceptions: PokemonException, which extends the Exception class. It must have a no-parameter constructo
    13·1 answer
  • Does -8 = -21?<br>[this is NOT a trick question]<br>Yes....?<br>No!​
    12·2 answers
  • Why is distance learning better
    12·2 answers
  • Function _one(array)
    6·1 answer
  • Does anyone know this? Can someone please help me? I’ll give brainliest!!
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!