File Format Team1 # Team number 5 # Number of Trukeys 25 30 23 22 21 # Weight of 5 turkeys, (each separated by space) end Team1 Team2 3 25 30 23 end Team2 Team3 # Team number # Number of Trukeys #Weight of 3 turkeys # Team number # Number of Trukevs

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

using Python, complete the table using the input.txt and displaying the table format shown in the question 

1
2
3
5
6
7
8
9
10
11
12
13
Input
The application input is a file with the information in the following format.
File Format
Team1
# Team number
5
# Number of Trukeys
25 30 23 22 21 # Weight of 5 turkeys, (each separated by space)
end Team1
Team2
3
25 30 23
end Team2
Team3
1
25
end Team3
−1
# Team number
# Number of Trukeys
# Weight of 3 turkeys
# Team number
# Number of Trukeys
# Weight of 1 turkey
#End of data
Processing and Output
Your program should accept the file as above ( You can create the above file
using notepad, notepad++, or any other text editor. Please do not use
Microsoft word to create the input file).
Read the input from the file and process it; the program will display summary statis-
tics for the teams. This will include a table with the weights of all turkeys caught and
the turkey count, total weight, heaviest turkey, lightest turkey, and average weight;
rank the teams based on the average weight; and write the result to another file (Use
python code within your program to write to the output file). The Table below gives
you an idea of what needs to be displayed on the screen. You should have the Title
description line in the file as the first line. Each Title can be separated with a Tab
or a Space, followed by one line per Team under the first line. Place the appropriate
information under the title, separated by a Space or a Tab.
Team name can be ten characters max. Other titles are an actual number of chars as
displayed. All the weights (0 to 100), two decimal places. Team Rank is an integer.
Teams Count W1 W2 W3 W4 W5 Total WT Heaviest Tky Lightest Tky Av. WT T Rank
Team 1 5
Team 2
Transcribed Image Text:1 2 3 5 6 7 8 9 10 11 12 13 Input The application input is a file with the information in the following format. File Format Team1 # Team number 5 # Number of Trukeys 25 30 23 22 21 # Weight of 5 turkeys, (each separated by space) end Team1 Team2 3 25 30 23 end Team2 Team3 1 25 end Team3 −1 # Team number # Number of Trukeys # Weight of 3 turkeys # Team number # Number of Trukeys # Weight of 1 turkey #End of data Processing and Output Your program should accept the file as above ( You can create the above file using notepad, notepad++, or any other text editor. Please do not use Microsoft word to create the input file). Read the input from the file and process it; the program will display summary statis- tics for the teams. This will include a table with the weights of all turkeys caught and the turkey count, total weight, heaviest turkey, lightest turkey, and average weight; rank the teams based on the average weight; and write the result to another file (Use python code within your program to write to the output file). The Table below gives you an idea of what needs to be displayed on the screen. You should have the Title description line in the file as the first line. Each Title can be separated with a Tab or a Space, followed by one line per Team under the first line. Place the appropriate information under the title, separated by a Space or a Tab. Team name can be ten characters max. Other titles are an actual number of chars as displayed. All the weights (0 to 100), two decimal places. Team Rank is an integer. Teams Count W1 W2 W3 W4 W5 Total WT Heaviest Tky Lightest Tky Av. WT T Rank Team 1 5 Team 2
Expert Solution
steps

Step by step

Solved in 2 steps with 6 images

Blurred answer
Knowledge Booster
File Input and Output Operations
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education