SAP interview question

Fizz buzz question from leetcode