• + 0 comments

    Here is my Python solution

    def migratoryBirds(arr):
        # Write your code here
        
        min_number = min(arr)
        max_number = max(arr)
    
        # Find the lowest type id of the most frequently sighted birds
        lowestId = max_number
        for i in range(max_number-1, min_number, -1):
            x = arr.count(i)
            if x >= (arr.count(lowestId)):
                lowestId = i
        return lowestId