Pregunta de entrevista de Synoriq

There was a coding question where I was asked to print a pattern.