
Dominando Bucles: For y While en Python 🐍
Authored by Pedro Orlando Gatica Guajardo
Computers
University
Used 2+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
¿Cuál es la principal diferencia entre un bucle for y uno while en Python?
for se usa solo con números, while con texto
while repite mientras una condición sea verdadera, for itera sobre una secuencia
Ambos son iguales
for se usa con condicionales, while con funciones
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
¿Qué imprime el siguiente código?
for i in range(3):
print(i)
1 2 3
0 1 2
0 1 2 3
1 2
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
¿Qué palabra clave debe usarse para salir de un bucle while en Python antes de que termine?
exit
stop
break
quit
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
¿Cuántas veces se ejecuta este ciclo for?
for i in range(5):
print("Hola")
4
5
6
infinito
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
¿Cuál de los siguientes códigos usa correctamente un bucle while?
while x < 5 { print(x) }
while x < 5: print(x)
while (x < 5) then print(x)
do while x < 5: print(x)
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Un bucle for siempre necesita una función range().
Verdadero
Falso
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
¿Qué función tiene este fragmento de código?
while respuesta.lower() != "sí":
respuesta = input("¿Quieres salir del bucle? (sí/no): ")
Ejecuta una vez y termina
Pregunta hasta que el usuario escriba "sí"
Siempre muestra "sí"
Tiene error de sintaxis
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
7 questions
ESBrotherX_Medical AI_Lecture
Quiz
•
University
12 questions
Python02
Quiz
•
University
15 questions
IT 209
Quiz
•
University
11 questions
Understanding Image Representation and Compression
Quiz
•
10th Grade - University
15 questions
Monday Week#2
Quiz
•
University
10 questions
1ª Recuperação - 3° Trim. - Pensamento Computacional - 9º ano
Quiz
•
9th Grade - University
10 questions
Arquitectura de computadoras
Quiz
•
University
10 questions
python test 1_23_24
Quiz
•
University
Popular Resources on Wayground
8 questions
2 Step Word Problems
Quiz
•
KG - University
20 questions
Comparing Fractions
Quiz
•
4th Grade
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
10 questions
Latin Bases claus(clois,clos, clud, clus) and ped
Quiz
•
6th - 8th Grade
22 questions
fractions
Quiz
•
3rd Grade
7 questions
The Story of Books
Quiz
•
6th - 8th Grade
Discover more resources for Computers
8 questions
2 Step Word Problems
Quiz
•
KG - University
7 questions
Comparing Fractions
Interactive video
•
1st Grade - University
7 questions
Force and Motion
Interactive video
•
4th Grade - University
10 questions
14.2 Independent/Dependent Variables
Quiz
•
KG - University
18 questions
Great Lakes States
Quiz
•
KG - University
7 questions
DNA, Chromosomes, Genes, and Traits: An Intro to Heredity
Interactive video
•
11th Grade - University
7 questions
Reflexive Verbs in Spanish
Lesson
•
9th Grade - University
7 questions
Narrative Writing 1
Interactive video
•
4th Grade - University