Instruções
Passo 6
Agora é hora de testar sua função
getPunctuationCount.
Crie uma variável punctuationCount e atribua a ela o resultado da chamada da função getPunctuationCount com o argumento "WHAT?!?!?!?!?"
Depois disso, registre o seguinte no console: "Punctuation Count: [Punctuation count goes here]". Substitua [Punctuation count goes here] pelo nome real da variável. Você pode optar por usar template strings ou concatenação de strings com o operador + aqui.
O que fazer:
Testes:
- Você deve criar uma variável `punctuationCount`.
- Sua variável `punctuationCount` deve ser definida com o resultado de `getPunctuationCount("WHAT?!?!?!?!?")`.
- Você deve registrar o seguinte no console: `"Punctuation Count: [Punctuation count goes here]"`. Replace `[Punctuation count goes here]` with the actual variable name. Certifique-se de usar a sintaxe correta de concatenação de strings aqui.
Console