Pergunta de entrevista da empresa Venerate Solutions

Logical reasoning and java coding question