Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Python Programming 1Tea Leaves Sales Report(python) 1. Here is the sample of the text file (datafile)for the tea sales (tea.txt) You have to create this
Python Programming
1Tea Leaves Sales Report(python) 1. Here is the sample of the text file (datafile)for the tea sales (tea.txt) You have to create this file yourself Green Tea 8580.0:720125:8900.0 Earl Grey:10225.25:9025.0:9505.0 Ceylon 6700.1:501245:8011.0 Jasmine:9285.15:8276.1:8705.0 Mint Tea:7901.25:4267.0:7056.5 The data reads as follows tea name:store1_Sales:store2_Sales:store3_Sales 2. The output displayed as follows: Ceylon Earl Grey Green Tea Jasmine Mint Tea 6700.10 5012.45 6011.00 7723.55 10225.25 9025.00 9505.00 28755.25 8580.00 201.25 8900.00 24681.25 9285.15 8276.10 8705.00 26266.25 7901.25 4267.00 7056.50 19224.75 42691.75 33781.80 40177.50 The last row is the store totals for all the kinds of tea leaves sold. The last column is the total sale for each kind of tea leaves sales. 3. 4. write a program to read in the tea-txt textfile and then print the report as shown in #2 above. You must use dictionary. You can also use list, tuples, sets if necessary 1222 AM
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started