Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

undefined New York City is a grid, or close to it. In that spirit we want to draw a shape like this: # # #

image text in transcribedimage text in transcribedundefined

New York City is a grid, or close to it. In that spirit we want to draw a shape like this: # # # # # # # # # # ##################### # # # # # # # # # # ##################### # # # # # # # # # # ##################### # # # # # # # # # # ##################### # # # # # # # # # # ##################### # # # # # # # # # # Ask the user for the width and height. Then draw this pattern for a height * width square. Hint: draw a grid of pound-signs (hashtags), then try to think about how mod can help you. Print spaces when you aren't printing #'s or else it'll all collapse together. Sample output: User input is generally colored blue to help distinguish it from the rest of the text. linux4[120]% python3 new_york_city.py What is the height of your grid: 1 What is the width of your grid: 1 [blank] linux4[121]% python3 new_york_city.py What is the height of your grid: 5 What is the width of your grid: 9 # # # # ######### # # # # ######### # # # # linux4 [122] % python3 new_york_city.py What is the height of your grid: 12 What is the width of your grid: 12 # # # # # # ############ # # # # # # ############ # # # # # # ############ # # # # # # ############ # # # # # # ############ # # # # # # ############

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Secrets Of Analytical Leaders Insights From Information Insiders

Authors: Wayne Eckerson

1st Edition

1935504347, 9781935504344

More Books

Students also viewed these Databases questions