Question: Programming 4: User-Defined Functions printURTriangle printDRTriangle Due on Sunday, 11/11/2018, by 11:59pm 3. New functions to define: a. for each shape choice, need a function
Programming 4: User-Defined Functions printURTriangle printDRTriangle Due on Sunday, 11/11/2018, by 11:59pm 3. New functions to define: a. for each shape choice, need a function to draw the Write a program named ProgramAssignment4_YourName.cpp to draw different shape according to the user choice. The given code is included in the box on the following page. The function body of main function is still pseudocode. You need to add necessary code to the given one to get a complete program: shape (function names are in the above list) b. these functions do not have returning value, so the function type is void 4. Add the prototype for all functions you have defined right 5. Add necessary preprocessor and namespace definition 6. In the comments on the top of the code, change the name before the main function before the function prototype list and date according to the local notes 1. Function Menu MakeChoice: a. function definition has been provided b. function call needs to be added the returning value is the choice of shape, validation check is needed i. c. function prototype needs to be added 2. A selection structure is needed to print different shape according to user's choice a. switch selection is the best structure since we know the possible value of user choice b. in each case (for a chosen shape), call a function to print the shape using asterisks (*). The function name should be: printsquare printRectangle
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
