Question d’entretien chez Nordic Semiconductor

Write a function to calculate how many sheep inside a ring