1. Write a program called Diamond.java that uses a method diamondOfAsterisks() that displays a diamond (the row number of a diamond must be odd) of asterisks whose row is specified in an integer parameter row. For example, if the user enters a 7, then the diamond will have seven rows and the method will display the pattern of asterisks. Below is an example of the diamond displayed when 7 is entered.

Leave a Reply

Your email address will not be published.