Question: double calculate _ bill ( char * in _ file, char * customer ) ; This function will open the file named in file, read
double calculatebillchar infile, char customer;
This function will open the file named in file, read the data, and calculate and return the
bill of the customer specified by customer. In case of errors, your function should return an
appropriate error code as described in section
The formula to calculate the bill b per row is given by
b n s x t
where n is the network usage in megabytes, s is the storage usage in blocks, x is the number of
servers used, and t is the number of hours the service is run. The bill is simply the sum of the
bills of each relevant row.
For example, for the input file
Science
Engineering
Science
for customer Science, the total bill is
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
