4
Answers

nested for structures

 Write a program that prints the following diamond shape. You may use output statements that print a single asterisk (*), a single space or a single newline character. Maximize your use of repetition (with nested for structures) and minimize the number of output statements. 
      *
    *** 
  ***** 
 *******
********* 
 *******
  *****
   *** 
     *

Answers (4)