How to count vowels in JavaScript using both for loop and regex

Published --