Answers for "function thaty counts number of vowels"

1

how to make a vowel counter in javascript

const vowelCount = str => {
  let vowels = /[aeiou]/gi;
  let result = str.match(vowels);
  let count = result.length;

  console.log(count);
};
Posted by: Guest on April-08-2020
1

how to make a vowel counter in javascript

function countVowels(str) {
  return str.match(/[aeiou]/g).length;
}
Posted by: Guest on April-09-2020

Code answers related to "function thaty counts number of vowels"

Code answers related to "Javascript"

Browse Popular Code Answers by Language