Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Challenge | Nested Loops
Python Loops Tutorial
course content

Conteúdo do Curso

Python Loops Tutorial

Python Loops Tutorial

1. The for Loop
2. The while Loop
3. Nested Loops

bookChallenge

Tarefa

  1. Initialize i.
  2. Configure the outer while loop to operate on the text.
  3. Initialize u.
  4. Establish the condition if an element is a letter.
  5. Configure the inner while loop to operate on vowels.
  6. Implement the condition if a letter from the text is found in vowels, then append it to text_vowels.
  7. Increment u.
  8. If the letter from the text is not found in vowels, then append it to text_consonants.
  9. If the element is not a letter, then append it to text_symbols.

Note

To determine whether a character is an alphabetic letter, you can utilize the .isalpha() method associated with a character (e.g., 'c'.isalpha()).

Switch to desktopMude para o desktop para praticar no mundo realContinue de onde você está usando uma das opções abaixo
Tudo estava claro?

Como podemos melhorá-lo?

Obrigado pelo seu feedback!

Seção 3. Capítulo 7
toggle bottom row

bookChallenge

Tarefa

  1. Initialize i.
  2. Configure the outer while loop to operate on the text.
  3. Initialize u.
  4. Establish the condition if an element is a letter.
  5. Configure the inner while loop to operate on vowels.
  6. Implement the condition if a letter from the text is found in vowels, then append it to text_vowels.
  7. Increment u.
  8. If the letter from the text is not found in vowels, then append it to text_consonants.
  9. If the element is not a letter, then append it to text_symbols.

Note

To determine whether a character is an alphabetic letter, you can utilize the .isalpha() method associated with a character (e.g., 'c'.isalpha()).

Switch to desktopMude para o desktop para praticar no mundo realContinue de onde você está usando uma das opções abaixo
Tudo estava claro?

Como podemos melhorá-lo?

Obrigado pelo seu feedback!

Seção 3. Capítulo 7
toggle bottom row

bookChallenge

Tarefa

  1. Initialize i.
  2. Configure the outer while loop to operate on the text.
  3. Initialize u.
  4. Establish the condition if an element is a letter.
  5. Configure the inner while loop to operate on vowels.
  6. Implement the condition if a letter from the text is found in vowels, then append it to text_vowels.
  7. Increment u.
  8. If the letter from the text is not found in vowels, then append it to text_consonants.
  9. If the element is not a letter, then append it to text_symbols.

Note

To determine whether a character is an alphabetic letter, you can utilize the .isalpha() method associated with a character (e.g., 'c'.isalpha()).

Switch to desktopMude para o desktop para praticar no mundo realContinue de onde você está usando uma das opções abaixo
Tudo estava claro?

Como podemos melhorá-lo?

Obrigado pelo seu feedback!

Tarefa

  1. Initialize i.
  2. Configure the outer while loop to operate on the text.
  3. Initialize u.
  4. Establish the condition if an element is a letter.
  5. Configure the inner while loop to operate on vowels.
  6. Implement the condition if a letter from the text is found in vowels, then append it to text_vowels.
  7. Increment u.
  8. If the letter from the text is not found in vowels, then append it to text_consonants.
  9. If the element is not a letter, then append it to text_symbols.

Note

To determine whether a character is an alphabetic letter, you can utilize the .isalpha() method associated with a character (e.g., 'c'.isalpha()).

Switch to desktopMude para o desktop para praticar no mundo realContinue de onde você está usando uma das opções abaixo
Seção 3. Capítulo 7
Switch to desktopMude para o desktop para praticar no mundo realContinue de onde você está usando uma das opções abaixo
some-alt