Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a program that prints the following diamond shape. Your printf statements may print either one asterisk (*) or one blank. Read an odd

imageimage

Write a program that prints the following diamond shape. Your printf statements may print either one asterisk (*) or one blank. Read an odd number in the range 1 to 19 to specify the number of rows in the diamond. Your program should then display a diamond of the appropriate size. Use nested for statements. please enter number of rows (odd nummber): 4 please enter number of rows (odd nummber): 7 Rubric 1.3 Criteria Detailed comment to explain every step of the solution Self explanatory variable names and good coding format (empty lines, indentation ect) Check use input is odd number, if not ask use to re-enter Use nested for statement Print out the diamond pattern as exptected program should include copywrite which contains the assignment number and your name 2 pts Full Marks 2 pts Full Marks 4 pts Full 5 pts Full Marks 5 pts Full Marks 2 pts Full Marks 2 pts Partial Ratings 0 pts No Marks 0 pts No Marks 0 pts No Marks 0 pts No Marks print out some patten with empty space and stars, but not the correct patten 0 pts No Marks 0 pts No Marks Pts 2 pts 2 pts 4 pts 5 pts 5 pts 2 pts Total Points: 20

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

Java How To Program Late Objects Version

Authors: Paul Deitel, Deitel & Associates

8th Edition

0136123716, 9780136123712

More Books

Students also viewed these Algorithms questions