Pergunta de entrevista da empresa Cloudbird Digital

Math problem which is difficult