Question
All that is needed is the CODE and it must be all done with C# in Visual Studio 2022. ONLY DO EXERCISE 6.24 , as
All that is needed is the CODE and it must be all done with C# in Visual Studio 2022. ONLY DO EXERCISE 6.24, as 6.23 is just there as a reference. The following additions MUST be added to the code as well. There are also other mandatory requirements below:
As specified in 6.23, only output a single character at a time (i.e. to display 4 asterisks, you would loop 4 times and in the loop body output a single asterisk).
Additions:
- Validate that your user enters an odd number between 1 and 19. - Have your user specify which one of four characters they would like to see displayed. You can pick whatever characters you want. Validate that the user correctly chooses one of the four. - Display a rectangle outline around your diamond; you can display a hyphen (-) and pipe (|) characters to get this effect.
6.23 (Displaying a Diamond) W rite an app that displays the following diamond shape. You may use output statements that display a single asterisk (), a single space or a single newline character. Maximize your use of iteration (with nested for statements) and minimize the number of output statements. 6.24 (Modified Diamond Program) Modify the app you wrote in Exercise 6.23 to read an odd number in the range 1 to 19 to specify the number of rows in the diamond. Your app should then display a diamond of the appropriate sizeStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started