Pregunta de entrevista de Enzigma

In f2f round they ask me to write a program for particular pattern printing