Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Problem: Well, with the recent merger of the BAA&M Railroad with the Kalamazoo, Erie & Rochester, you find yourself working for the KERBAA&M in a

Problem:
Well, with the recent merger of the BAA&M Railroad with the Kalamazoo, Erie & Rochester, you find yourself working for the KERBAA&M in a new location. You are now required to produce very specifically formatted reports for your new hot-tempered management.
The data file should have the following information (Each item is on a separate line):
Name of Railroad
Destination
Number of ore cars
Current price of Coal per short ton.
You need to calculate:
1. the amount of coal,
2. the total value of the shipment, and
3. the surcharge.
Assume that every car holds 74.5 tons. The surcharge is set at 0.31% of the total value of the shipment.
You need to produce a report formatted EXACTLY as follows (with your name):
KERBAA & M COAL TRAIN REPORT
Railroad Name: Ironton and Tylerville
Destination: Flint Edison #4
Number of ore cars:............ 87
Total weight of coal........... 6481.50 short tons
Current Cost per short ton..... $ 65.47
Total Value of Shipment........ $ 424343.81
Current Surcharge.............. 0.31%
Total Surcharge(Est)........... $ 1315.47
You must run your program from a file containing the following data:
Ironton and Tylerville
Flint Edison #4
87
65.47
All output must be sent to an output file. Be sure that your program is well documented and written in good style. Your program should round to the nearest penny and hundredth of a ton. You should take advantage of setfill characters. Your program should produce output formatted the same way, even for different values. (The decimal point still lined up, etc.)
You must turn in a copy of your program, a copy of the output file and a copy of the input file.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Concepts of Database Management

Authors: Philip J. Pratt, Joseph J. Adamski

7th edition

978-1111825911, 1111825912, 978-1133684374, 1133684378, 978-111182591

More Books

Students also viewed these Databases questions

Question

What is the difference between Wi-Fi and WiMAX communications?

Answered: 1 week ago

Question

x-3+1, x23 Let f(x) = -*+3, * Answered: 1 week ago

Answered: 1 week ago