Question d’entretien chez Amazon

Write a function to get the most repeated word in a string.

Réponse à la question d'entretien

Utilisateur anonyme

7 janv. 2011

I started droning about tokenizing words and storing them in an array and then switched to a hash table when all it really needed was to sort all the words using strcmp and maintain a count for each word and return the word with the maximum count.