fixed some spellings

This commit is contained in:
Keshav Bohra
2021-10-05 12:49:23 +05:30
parent 199d2637cc
commit 1589263947
41 changed files with 80 additions and 80 deletions

View File

@ -1,15 +1,15 @@
// Given a sentence, return the most occuring word
// Given a sentence, return the most occurring word
/**
* @param {string} sentence - the sentence you want to find the most occuring word
* @returns {string} - the most occuring word
* @param {string} sentence - the sentence you want to find the most occurring word
* @returns {string} - the most occurring word
*
* @example
* - maxWord('lala lili lala'); // lala
*/
const maxWord = (sentence = '') => {
if (typeof sentence !== 'string') {
throw new TypeError('the param sould be string')
throw new TypeError('the param should be string')
}
if (!sentence) {