Pergunta de entrevista da empresa Synchrony

They asked me to reverse a string without functions