Skip to content · ⁨Pular para o conteúdo⁩

Count the vowels · ⁨Contar vogais⁩

English

Count the vowels

Count the vowels (a e i o u) in a String, treating upper- and lower-case the same. Lower-case it first with s.toLowerCase(), then loop with s.charAt(i) and compare against each vowel.

Português

Conte as vogais

Conte as vogais (a e i o u) em um String, tratando maiúsculas e minúsculas como iguais. Minimize primeiro com s.toLowerCase(), depois faça um loop com s.charAt(i) e compare contra cada vogal.

Log in or create account · ⁨Entrar ou criar conta⁩

IGCSE, A-Level & AP