Whale talk - step 8

Hello all,

May I know wt is missing and the console.log is showing nothing.

The string assigned to the input variable is uppercase i.e. 'ESKETITT', whereas the elements of the vowels array are lowercase. Consequently, your if condition will not be true and nothing will be logged to the console.

If you change the string to:

const input = 'esketitt';

then, 'e', 'e' and 'i' will be logged to the console.

If you want to allow uppercase strings as well, then you can use the toLowerCase() method:

const input = 'ESKETITT';
...
    if (input[inputIndex].toLowerCase() === vowels[vowelIndex]) {
            console.log(input[inputIndex]);
    }
2 Likes

Thanks for answering.
I’m on the last step and got stuck again.
Could you please help me check?
BTW I feel so frustrated since I got stuck with task for 2days LOL

You have a typo.

You wrote topUpperCase() instead of toUpperCase()

1 Like