Questions LLC
Login
or
Sign Up
Ask a New Question
Loops
Page 3
Questions (131)
The program below will ask the user for an input phrase. The program should then use a "for" loop to iterate over the string,
3 answers
asked anonymously
20 views
The program below will ask the user for an input phrase. The program should then use a "for" loop to iterate over the string,
1 answer
asked anonymously
21 views
The program below leads the user through a classic "Knock Knock" joke. The user must enter the word "Banana" two times at the
1 answer
asked anonymously
30 views
In this chapter, you learned how to create for() and while() loops. You also learned how to use break and continue to halt a
1 answer
asked anonymously
36 views
How many times will the body of the following loop be run?
secret = input("Guess my secret: ") while secret != "I am a
1 answer
asked anonymously
27 views
The program below should repeatedly take a user's food order and echo the message "Yum, I love X", where X is the input food.
1 answer
asked anonymously
36 views
Explain how loops can be utilized in list processing. Please provide Python examples in your response.
1 answer
asked anonymously
53 views
What kind of program construct has a looping branch of code?
(1 point) Responses sequence sequence selection selection iteration
1 answer
asked anonymously
64 views
In the code below, which statement(s) are part of the "for" loop body?
sum = 0 #LINE 1 for index in range(0,10): # LINE 2 sum =
1 answer
asked anonymously
23 views
Which of the following best describes how many times the statements in the body of a "while" loop will run?
Responses A maximum
1 answer
asked anonymously
29 views
What kind of program construct has a looping branch of code? (1 point) Responses sequence sequence selection selection iteration
1 answer
asked anonymously
34 views
The program below initializes a list with integers between two user-entered numbers. It should then traverse or iterate through
1 answer
asked anonymously
33 views
The program below initializes a list with integers between two user-entered numbers. It should then traverse or iterate through
1 answer
asked anonymously
30 views
What kind of program construct has a looping branch of code?
(1 point) Responses sequence sequence selection selection iteration
1 answer
asked by
100%
43 views
Verify that the user enters a positive value. (use a while loop)
1 answer
asked anonymously
12 views
chorus = 3 for i in range(chorus): print("Let's dance!") (1 point) Responses Let’s dance! Let’s dance! Let’s dance!
1 answer
asked by
Johovah_Witness
30 views
Lars is writing an algorithm that asks the user to enter a correct password. What type of iteration is Lars including in his
1 answer
asked anonymously
13 views
Why might you use a "while True:" loop to surround your user input and validation logic?
Select one: a. You want to ask the user
1 answer
asked anonymously
23 views
In which of these situations would it make the MOST sense to use a while loop?
(1 point) Responses if the user has three lives in
1 answer
asked by
Shogun
13 views
Which structure should you use if you don’t know in advance how many times a loop should execute?
(1 point) Responses a for
1 answer
asked by
Shogun
21 views
Which kind of loop has the incrementing variable initialized BEFORE the loop begins?
(1 point) Responses a for loop a for loop an
1 answer
asked by
Shogun
17 views
In this first line of a JavaScript for loop, what is i<=10 called?
for (let i=1; i<=10; i++){ (1 point) Responses the
1 answer
asked by
Shogun
9 views
Which kind of loop has the incrementing variable initialized BEFORE the loop begins?
a for loop an initialized loop a while loop
1 answer
asked anonymously
13 views
Which structure should you use if you don't know in advance how many times a loop should execute?
a for loop an initialized loop
1 answer
asked anonymously
13 views
What will be the output of these lines of code? for i in range (1, 5): print(i) (1 point) Responses IndentationError
1 answer
asked anonymously
29 views
Which structure should you use if you don’t know in advance how many times a loop should execute?
a for loop an initialized
1 answer
asked anonymously
11 views
In this first line of a JavaScript for loop, what is i called?
for (let i=1; i<=10; i++){
3 answers
asked anonymously
8 views
In which of these situations would it make the MOST sense to use a while loop?
if the user has three lives in the game if the
1 answer
asked anonymously
13 views
Which kind of loop has the incrementing variable initialized BEFORE the loop begins?
a for loop an initialized loop a while loop
1 answer
asked anonymously
11 views
Loops in c programming
1 answer
asked anonymously
3 views
What will be the output of these lines of code?
for i in range (1, 5) : print ( i ) A. IndentationError B. PrintError C. 1234 D.
1 answer
asked anonymously
4 views
Pages
1
2
3
Parent Categories (23)
Algorithms
C programming
Code Constructs
Code Execution
Coding terms
Computer Programming
Computer Science/Programming
Control Flow
Control structures
Java
Java programming
Javascript
Programming
Programming Basics
Programming Concepts
Programming Structures
Pseudo Code
Python
Python Programming
QBASIC Programming
Source Code
Syntax
Visual Basic