final int ROWS = 2;
final int COLS = 12;
for ( int row = - ROWS; row <= ROWS; ++row)
{
for (int col = 1; col <= COLS; ++col)
{
int limit = row >= 0 ? ROWS - row : ROWS + row;
limit *= 2;
char c = col <= limit ? ' ' : '*';
System.out.print(c);
}
System.out.println();
}