Answered step by step
Verified Expert Solution
Question
1 Approved Answer
I seen this post multiple times but none of them works because i need to displays the answer in a certain way and other answers
I seen this post multiple times but none of them works because i need to displays the answer in a certain way and other answers are slighty modify . I need the answer with a screenshot of the code in Phyton mode with the colors and everything on it so i see exactly where my mistake occured , here's a screenshot of my work :
Flowers.pyflowers.dat Opening Files and 1 # FLowers.py . This program reads names of flowers and whether they are grown Performing File Input in shade or sun from an input 2# file and prints the information to the user's screen 3 #Input: flowers.dat 4 # Output: Nares of flowers and the words sun or shade Summary In this lab, you open a file and read input from that file in a prewritten Python program. The program should read and print the names of flowers and whether they are grown in shade or sun. The data is stored in the input file named flowers.dat 7 # Open input file 8 myFlowers open("flowers.dat,"r" myFlowers, readline() 9 10 var var2myFlowers.readline() 12 # Write while loop here 13 while var != "EOF" and var2 != ""- 14 15 16 var myFlowers.readline() 17 var2myFlowers.readline() 18 nyFlowers.close # Print flower nane using the following format print (var "grows in the" var2) Instructions 1. Open the source code file named 2. Write a while loop to read the input 3. In the body of the loop, print the Flowers.py until EOF is reached. name of each flower and where it can be grown (sun or shade). 4. Execute the program. Your program exceeded the maximum 5,000 lines of output Grading Run Code Test Grade When you have completed your
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