Pergunta de entrevista da empresa Novigo Solutions

They asked me a question to find the 2nd largest number in array and write a optimised code.