Question
In python 3, write a program that takes an input text file containing the following: name: James age: 20 shirt:polo color:blue shirt:tshirt color:purple shirt: sleeveless
In python 3, write a program that takes an input text file containing the following:
name: James age: 20 shirt:polo color:blue shirt:tshirt color:purple shirt: sleeveless color: orange
And writes an output text file containing the following ONLY if the age of the person in the text file is 20: name: James
shirts: 1. polo 2. sleeveless 3. tshirt
james has the shirt: polo the color is: blue
james has the shirt: tshirt the color is: purple
james has the shirt: sleeveless the color is: orange
REQUIREMENT: This program must be able to produce an output in the same format regardless of how many tshirts the person has in the input.txt file.
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