English
English, 28.04.2021 04:00, edog32

(Wattan Corporation) is an Internet service provider that charges customers a flat rate of $7.99 for up to 10 hours of connection time. Additional hours or partial hours are charged at $1.99 each.
Write a function charges that computes the total charge for a customer based on the number of hours of
connection time used in a month. The function should also calculate the average cost per hour of the time
used (rounded to the nearest 0.01), so use two output parameters to send back these results.
You should write a second function
round_money that takes a real number as an input argument and returns as the function value the number
rounded to two decimal places. Write a main function that takes data from an input file usage. txt and
produces an output file charges. txt. The data file format is as follows:
Line 1: current month and year as two integers
Other lines: customer number (a five-digit number) and number of hours used
Here is a sample data file and the corresponding output file:
Data file usage. txt
10 2009
15362 4.2
42768 11.1
11111 9.9
Output file charges. txt
Charges for 10/2009
15362 4.2 7.99 1.90
42768 11.1 10.18 0.92
11111 9.9 7.99 0.81

answer
Answers: 2

Other questions on the subject: English

image
English, 22.06.2019 03:00, manny2085
Analyze the graphic organizer below and answer the question that follows. / which element is necessary to complete the graphic organizer? complex sentence prepositional phrase subordinate clause independent clause the. i think it might be c but idk
Answers: 3
image
English, 22.06.2019 04:30, talia43
What is the author's purpose in both patrick henry's speech and thomas paines common sense
Answers: 2
image
English, 22.06.2019 08:00, lawhd8700
Who are the queens with morgan le fay? what is significant about one of them
Answers: 1
image
English, 22.06.2019 09:30, sonyfan
What can you infer about how the particular events in "the memoirs of the conquistador bernal del diaz de castillo" still affected the writer at the time of writing his memoir? he thinks of his dead crewmen with sadness and regrets that they died for nothing. he is still frustrated that one of his men accidentally kills himself by drinking too much water.  he thinks wistfully about the wealth he may have enjoyed if they had found gold in the yucatan.  he still considers indians liars. 
Answers: 3
Do you know the correct answer?
(Wattan Corporation) is an Internet service provider that charges customers a flat rate of $7.99 for...

Questions in other subjects:

Konu
Mathematics, 21.05.2021 19:10
Konu
French, 21.05.2021 19:10
Konu
Social Studies, 21.05.2021 19:10