Reference no: EM131119675
ClassAverage
Objective:
• Creating a program that uses a .txt file as input
• Creating a program that will generate a .txt output file
• Exception Handling Requirements:
You'll be given a text file, called mstu4031_input.txt. That file will contain a list of grades.
Your job this week is to write a program that will read the file, and then generate an
output file that contains a class average and feedback. If the program cannot find the
input file in your BlueJ project directory, it will throw an IOException.
• Create a BlueJ project
• Add mstu4031_input.txt to the folder
• Now build your program
• Scanner Class
• DecimalFormat Class
• While loop
• Try/catch
• If/else if/else
• The program should produce a .txt output file (it will also live in the BlueJ folder)
o Call it "mstu4031_output.txt"
o List the values on separate lines
o Generate a class average
o Provide a feedback statement
MSTU4031: Lab - Calculating a Class Average Results should look something like this:
Lab 13
Input file name (from your computer): abc.txt
ERROR
Cannot locate the input file 'abc.txt' on your computer - please try again.
Input file name (from your computer): mstu4031_input.txt
What would you like to call your output file: mstu4031_output.txt
INPUT FILE FOUND, OUTPUT FILE GENERATED
Your input file, mstu4031_input.txt, has been found and accepted.
Your output file, mstu4031_output.txt, has been created.
mstu4031_output.txt is living in your BlueJ project directory.
Please open mstu4031_output.txt for the class's average and feedback. Results Screenshots:
Define product placement
: Define Product Placement. What are two product placement options? Why have marketers increased their use of product placements? How does the development of a creative strategy help the marketer?
|
Measure of an effective police administrator
: The measure of an effective police administrator is often taken by how well the prepare, present, and execute the department budget. Please explain, with examples, what this means.
|
What is the main benefit of the benzodiazepine class
: What is the main benefit of the benzodiazepine class with regard to usage as anesthetic induction agents
|
The merchandise was originally sold with a gross profit rate
: The merchandise was originally sold with a gross profit rate of 30%. Prepare the entries on the books of Seaver Company to record all transactions related to Noble during 2010. (Ignore interest charges.)
|
Creating a program that will generate a txt output file
: Creating a program that uses a .txt file as input. Creating a program that will generate a .txt output file. You'll be given a text file, called mstu4031_input.txt. That file will contain a list of grades.
|
Doctor freely prescribes these narcotics to people
: do you think that doctors should face any legal consequences if they continue to prescribe narcotics to an individual over a long period of time, and it has become obvious that the doctor freely prescribes these narcotics to people?
|
Should the patient be started on tpn
: Mrs. Hanes is a 62-year-old woman with metastatic breast cancer. She was admitted with dehydration and weakness. Should the patient be started on TPN
|
Installment sales default and repossession crawford
: An oven that cost $1,200 was sold to Travis Longman for $1,500 on the installment basis. Longman made a down payment of $240 and paid $80 a month for six months, after which he defaulted. The oven was repossessed and the estimated fair value at time ..
|
One of the metrics used in non-traditional media
: One of the metrics used in non-traditional media (internet, social media, etc.) is engagement. Explain what is meant by engagement and why it is important to the marketer. Studies have shown that email marketing is much more effective than traditiona..
|