Write a program that reads the number of hours each person spent on Facebook on specific day. The number of hours is a positive integers. First zero or negative integer will terminate the input. The program finds the total number of hours spent on Facebook by all people and the number of people who spent 4 hours and more on Facebook that day.
Write a program that reads a number of parking violations person got per year. The program reads the category for each violation (assume that the input is an integer 1, 2, or 3. Assume that the input is VALID). The program finds the total amount paid for parking violations, the average violation fine and the number of violations in EACH category. Use the table below.
Violation Category | Violation Fine |
1 | $35 |
2 | $50 |
3 | $75 |