Pergunta de entrevista da empresa Works Applications

Array sorting and pattern printing problems.