Question d’entretien chez FlightAware

Find the smallest value in an integer array without sorting it. Assume that there is no Array.min() method. Sample input: {0, 1, 2, -50, 100, 0}

Réponse à la question d'entretien

Utilisateur anonyme

22 juil. 2016

A = input I = A[0] for x in A[1:]: If x < I: I = x print I