Question: python 3 help Objective: Write a program that makes use of the topics covered in the course to solve a problem Problem: Using python, write

python 3 help

python 3 help Objective: Write a program that makes use of the

topics covered in the course to solve a problem Problem: Using python,

Objective: Write a program that makes use of the topics covered in the course to solve a problem Problem: Using python, write a program that will simulate a special physics demonstration Imaging a number of wooden matches are arranged upright on a grid. The matches are positioned at the same level and at integer location (inches) on an X-Y grid. A special laser is placed at the origin that projects a fan of laser light onto the field of matches. Consider "L: as the laser position and "." as the matches, from above: From the side a row looks like: When the laser fires, it will ignite the matches that it can "see", with some of the matches blocking the view from to the matches behind them. For example, along a given line, only the first match will ignite 0 0 0 Lit Unlit Unlit Unlit We would like to know which (or how many) matches in the field are ignited and which (or how many) are not. Deadline: Tuesday, May 8, 2018, 11:59 PM Requirements: Submit to Blackboard a single python file named "homework4.??". Include in the header your name, PSID, and the homework number. Use meaningful variable and function names in order to: Request the name for the output file to be used to save the results. Request the width and height of the field as positive whole numbers Determine the matches which are ignited and which are not If both the sizes are below 80, display the results and write the result into a file with the specified name. If either value is above that, simply display and record to the file the number of lit and unlit matches Use the program to answer the question: How many matches are unlit for a 1000x 1000 field? Use good functional style and suitable variable names 1. 2. 3. 4. 5

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!