Question: Design and write a program in Java that will prompt the user to enter an integer value. This integer value will be used by the
Design and write a program in Java that will prompt the user to enter an integer value. This integer value will be used by the program toprint out a series of right triangles built out of asterisks Each of the triangles will be printed out one asterisk at a time using loops. Each of the triangles should be between three to nine asterisks high and the same number across, but in different configurations.When printing out the triangles, you may only System.out.print either of the following: or a blank space or an asterisk.You may not print more than one character at a time. You may of course use System.out.println;to print a new line for spacing and formatting purposes.To build the triangles, use loops that count how many elements have been printed of each type. Be sure to use variables to keep track of how many asterisks and spaces have been printed to use in the controlling boolean expressions. This program should print squares in different orientations per integer
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
