This preview shows page 1. Sign up to view the full content.
Unformatted text preview: rom 0 to 100, is
to be searched to find how many of them are above 90. The total has to be printed.
Prepare a flowchart to do this job. Assume a suitable sentinel value for the trailer record.
54. Each paper in a set of examination papers includes a grade of A, B, C, D, or E. A
count is to be made of how many papers have the grade of A and how many have the
grade of E. The total count of both types have to be printed at the end. Prepare a
flowchart to perform this task. Assume a suitable sentinel value for the trailer record.
55. A shopkeeper wants to have a general program for his personal computer that will
prepare bills for each customer as and when he sells goods to them. His idea is that as
soon as the customer purchases some goods from his shop, he will supply the description,
unit price, and the quantity purchased for each item, as input to the computer. He wants
that with this information, the computer should print each item along with its unit price,
quantity purchased and the total price. Finally, the computer should also print the total
cost of all the items purchased by the customer. Assuming that a sentinel value of zero is
used for the quantity purchased field in the trailer record, draw a flowchart for the logic
to do this job.
56. An employer plans to pay bonus to each employee. Those earning Rs. 2000 or above
are to be paid 10 percent of their salary; those earning less than Rs. 2000 are to paid Rs.
200. The input records contain the employee number, name, and salary of the employees. The output to be printed should contain the employee number, name, and the amount of
bonus to be paid to each employee. Draw a flowchart for the algorithm to do this job.
Assume a suitable sentinel value for any of the fields of the trailer record.
57. Each employee pay record includes the hours worked and the pay rate. The gross pay
is to be determined as hours worked times pay rate and is to be printed for each
employee. For all hours worked in excess of 40, the overtime rate, which...
View Full Document
- Spring '14