Question d’entretien chez Cognizant

Ine Java they give me to code star pattern...(Triangle shape)