Pergunta de entrevista da empresa Imagine Communications

Fizz buzz coding question. Was also asked to solve without using modulus