Domain changed to archive.palanq.win . Feb 14-25 still awaits import.
[13 / 3 / 5]

Java help

No.1277844 View ViewReplyOriginalReport
Any idea what loops I should use for this?

Problem “Triangles” Write a program to create the following figure by using nested for loops. Please use parameters in order to change the size and number of triangles as in the examples below, while being able to reuse the code. Desired output for SEGMENT = 3 and HEIGHT = 4

*
***
*****
*******
*
***
*****
*******
*
***
*****
*******

Desired output for SEGMENT = 2 and HEIGHT = 6

*
***
*****
*******
*********
***********
*
***
*****
*******
*********
***********