For...of
For...of
for...of loops over values directly, which makes it useful for reading each character in a string without managing numeric indexes.
Your task: Use a for...of loop to count how many vowels appear in word. Store the number in vowelCount and log it.
Free with a JS Exercises account
Sign in to start coding, run your solution, and keep your progress saved for later. No payment needed.
By continuing, you agree to our Terms and Privacy Policy. We'll send occasional product updates and news. You can unsubscribe anytime.
For...of
for...of loops over values directly, which makes it useful for reading each character in a string without managing numeric indexes.
Your task: Use a for...of loop to count how many vowels appear in word. Store the number in vowelCount and log it.