Bel-Technology Interview Question

Java pattern for stars print