subject

Your task is to write python program that draws a board with alternating dark cells (black or some other color) and white cells. The number of cells to use in each row or column, width of each cell, and color to use for dark cells (either black, red, green, or blue) should be collected from the keyboard after showing appropriate input prompt messages. Note the following requirements: • The program can either start with a dark (colored) cell or white cell. In the figure below, the board starts with dark cell.
• The program should draw an N by N board where N is the number of cells in a row (or a column). Note that the shape of board and the cells are both square.
• The program should draw a border (black line) around the board as shown in the figure.
• The program must prompt for input from the keyboard and then validate the input as follows:
o Number of cells in each row or column must be positive number > 1
o Width of each cell must be a positive number > 9
o The color can be one of 4 colors only: black, red, green or blue.
• If any of the provided input is invalid then the program should show a warning message and use the default value for that variable as follows:

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 12:30
Svieta is making a chart of the hours that different employees have put into a team project at work. what formula would autosum most likely generate if added into b8?
Answers: 1
question
Computers and Technology, 23.06.2019 09:50
Allison and her group have completed the data entry for their spreadsheet project. they are in the process of formatting the data to make it easier to read and understand. the title is located in cell a5. the group has decided to merge cells a3: a7 to attempt to center the title over the data. after the merge, allison points out that it is not centered and looks bad. where would the title appear if allison unmerged the cells in an attempt to fix the title problem?
Answers: 2
question
Computers and Technology, 23.06.2019 12:30
Animations and transitions are added from the
Answers: 1
question
Computers and Technology, 24.06.2019 15:30
What is the total number of time zones that can be configured to show by default in a calendar in outlook 2016?
Answers: 1
You know the right answer?
Your task is to write python program that draws a board with alternating dark cells (black or some o...
Questions
question
Mathematics, 08.03.2021 21:40
question
English, 08.03.2021 21:40
question
Chemistry, 08.03.2021 21:40
question
Mathematics, 08.03.2021 21:40
question
Mathematics, 08.03.2021 21:40
question
English, 08.03.2021 21:40
Questions on the website: 13722367