Pergunta de entrevista da empresa Amdocs

There were 4 questions in interview and with regular competitive coding, one can clear it.