Question: Please help with this C++ problem Write a program that draws shapes on the console. The program will execute in a while loop to display
Please help with this C++ problem


Write a program that draws shapes on the console. The program will execute in a while loop to display a menu to the user. Users can select among 4 different shapes: a filled rectangle, an empty rectangle, a filled triangle, and an empty triangle. In order to draw a rectangle on the console, the program must request the desired width and height of the rectangle. Once the user enters these parameters, the program will use a nested for loop to draw the rectangle. For triangles, the program will request the height of the triangle before drawing a triangle of given height. For both rectangle and triangle shapes, users can select to fill each shape with the character or draw them empty with the ank space. The sample output for the filled rectangle option is provided below. 1. Filled Rectangle 2. pty Rectangle 3. Filled Triangle 4. Empty Triangle 5. Exit Enter option: 1 Enter height: 4 Enter width 1. Filled Rectangle 2. Empty Rectangle 3. Filled Triangle 4. Empty Triangle 5. Exit Enter option: 5 Good bye! The sample output for the empty rectangle option is provided below. 1. Filled Rectangle 2. Empty Rectangle 3. Filled Triangle 4. Empty Triangle 5. Exit Enter option: 2 Enter height: 6 Enter width 1. Filled Rectangle 2. Empty Rectangle 3. Filled Triangle 4. Empty Triangle 5. Exit Enter option: 5 Good bye
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
