FOR JAVA Write a method called pyramid that takes a number, a character, and a boolean as parameters. Then the method should print a pyramid accord- ing to parameters (please see the example below)....


FOR JAVA





Write a method called pyramid that takes a number, a character, and a boolean as parameters. Then the method should print a pyramid accord- ing to parameters (please see the example below). In the main method, ask user to enter values for your method’s parameters and call your method.


OUTPUT:

ENTER A NUMBER

3

ENTER A CHARACTER

o

Is pyramid upside down?

false

o

oo

ooo

Enter a number

5

Enter a character

*

Is pyramid upside down?

true

*****

****

***

**

*






Jun 08, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here