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

Contenido del Curso

Python Loops Tutorial

Python Loops Tutorial

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

Challenge

Tarea

  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()).

Tarea

  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()).

Cambia al escritorio para practicar en el mundo realContinúe desde donde se encuentra utilizando una de las siguientes opciones

¿Todo estuvo claro?

Sección 3. Capítulo 7
toggle bottom row

Challenge

Tarea

  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()).

Tarea

  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()).

Cambia al escritorio para practicar en el mundo realContinúe desde donde se encuentra utilizando una de las siguientes opciones

¿Todo estuvo claro?

Sección 3. Capítulo 7
toggle bottom row

Challenge

Tarea

  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()).

Tarea

  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()).

Cambia al escritorio para practicar en el mundo realContinúe desde donde se encuentra utilizando una de las siguientes opciones

¿Todo estuvo claro?

Tarea

  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()).

Cambia al escritorio para practicar en el mundo realContinúe desde donde se encuentra utilizando una de las siguientes opciones
Sección 3. Capítulo 7
Cambia al escritorio para practicar en el mundo realContinúe desde donde se encuentra utilizando una de las siguientes opciones
We're sorry to hear that something went wrong. What happened?
some-alt