Pergunta de entrevista da empresa Nordic Semiconductor

Write a function to calculate how many sheep inside a ring