A majority element in an array of size n is an element that appears more than n/2 times. Check out some algorithms on how to find the majority element: http://www.geeksforgeeks.org/majority...
In this video, we are working out an approach using javascript objects and their fast access time to write a linear time algorithm for this problem.
Find more exercises on the AlgorithmProblemBot's twitter page: / algorithmproble (yes, that's the correct URL :) )
En esta página del sitio puede ver el video en línea Javascript Array Exercise: Majority Element de Duración hora minuto segunda en buena calidad , que subió el usuario LEAN-CODERS 10 mayo 2016, comparta el enlace con amigos y conocidos, en youtube este video ya ha sido visto 5,468 veces y le gustó 46 a los espectadores. Disfruta viendo!