Pergunta de entrevista da empresa Wi-Tronix

Coding question was easy regarding arrays