Pergunta de entrevista da empresa Amazon

How would you select a random element from an array