Pergunta de entrevista da empresa Bloomberg

Remove every nth element from cyclical elements and return the index