Pergunta de entrevista da empresa Amazon

What is the complexity of your algorithm for the above problem. Can you reduce the complexity