akosiraff

Download BrewsterSales Python Answer

Jan 18th, 2017
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.67 KB | None | 0 0
  1.  
  2. Download: https://solutionzip.com/downloads/brewstersales-python/
  3. Brewster’s Used Car, Inc. employs several salespeople. Brewster, the owner of the company, has provided a file named sales.txt that contains the sales records for each salesperson for the past month. Each record in the file contains the following two fields:
  4. The salesperson’s ID number, as an integer
  5. The amount of a sale, as a real number
  6. The records are already sorted by salesperson ID. Design a program that prints a sales report. The report should show each salesperson’s sales and the total sales for that salesperson. The report should also show the total sales for all salespeople for the month. Here is an example of how the sales report should appear:
  7. Brewster’s Used Cars, Inc.
  8. Sales Report
  9. Salesperson ID Sale Amount
  10. ======================================…
  11. 100 ==== $10,000.00
  12. 100 ==== $12,000.00
  13. 100 ==== $5,000.00
  14. Total sales for this salesperson : $27,000.00
  15. 101 ==== $14,000.00
  16. 101 ==== $18,000.00
  17. 101 ==== $12,500.00
  18. Total sales for this salesperson : $44,500.00
  19. 102 ==== $13,500.00
  20. 102 ==== $14,500.00
  21. 102 ==== $20,000.00
  22. Total sales for this salesperson : $48,000.00
  23. Total of all sales: $119,500.00.
  24. Here is the text file containing the sales report
  25. Salesperson ID Sale Amount
  26. ======================================…
  27. 100 ==== 10000.00
  28. 100 ==== 12000.00
  29. 100 ==== 5000.00
  30. 101 ==== 14000.00
  31. 101 ==== 18000.00
  32. 101 ==== 12500.00
  33. 102 ==== 13500.00
  34. 102 ==== 14500.00
  35. 102 ==== 20000.00
  36. 103 ==== 8000.00
  37. 103 ==== 15000.00
  38. 103 ==== 18500.00
  39. 104 ==== 23000.00
  40. 104 ==== 6800.00
  41. 104 ==== 9700.00
  42. 104 ==== 11500.00.
  43.  
  44. Download: https://solutionzip.com/downloads/brewstersales-python/
Add Comment
Please, Sign In to add comment