Below are several scripts, each involving a while loop. Select each of the scripts in which the code inside the while loop is run exactly once. ✓a. 1 = [1, 1] while 4 not in 1: 1.append(sum(1)) b. 1 = [1] m = 1 i = 2 while len(1)<3: 1.append(i) m.append(1+1) i = 1+1 c. 1 = range (17, 97) while 1: 1 = = 1[20:-20] ✓ d. x = 100 while x>0: S = 0 for x in range(100, -1, -1): S = 5+1 ༣ ✓ f. e. 1 = [1] m = 1 i = 2 while m is 1: 1 = 1+[i] m = 1+[i+1] i = 1+1 f = lambda x: lambda y: while f!=0: f = f(0)
Below are several scripts, each involving a while loop. Select each of the scripts in which the code inside the while loop is run exactly once. ✓a. 1 = [1, 1] while 4 not in 1: 1.append(sum(1)) b. 1 = [1] m = 1 i = 2 while len(1)<3: 1.append(i) m.append(1+1) i = 1+1 c. 1 = range (17, 97) while 1: 1 = = 1[20:-20] ✓ d. x = 100 while x>0: S = 0 for x in range(100, -1, -1): S = 5+1 ༣ ✓ f. e. 1 = [1] m = 1 i = 2 while m is 1: 1 = 1+[i] m = 1+[i+1] i = 1+1 f = lambda x: lambda y: while f!=0: f = f(0)
Chapter8: Arrays
Section: Chapter Questions
Problem 5PE
Related questions
Question
![Below are several scripts, each involving a while loop.
Select each of the scripts in which the code inside the while loop is run exactly once.
✓a. 1 = [1, 1]
while 4 not in 1:
1.append(sum(1))
b. 1 = [1]
m = 1
i = 2
while len(1)<3:
1.append(i)
m.append(1+1)
i = 1+1
c. 1 = range (17, 97)
while 1:
1 = = 1[20:-20]
✓ d. x = 100
while x>0:
S = 0
for x in range(100, -1, -1):
S = 5+1
༣
✓ f.
e.
1 = [1]
m = 1
i = 2
while m is 1:
1 = 1+[i]
m = 1+[i+1]
i = 1+1
f = lambda x: lambda y:
while f!=0:
f = f(0)](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2Fa2dbdd1c-b92a-4076-a30c-fb21b48d7076%2F3413d001-8d38-46bd-94b7-0d20bcf612fc%2Fmn7wt8_processed.png&w=3840&q=75)
Transcribed Image Text:Below are several scripts, each involving a while loop.
Select each of the scripts in which the code inside the while loop is run exactly once.
✓a. 1 = [1, 1]
while 4 not in 1:
1.append(sum(1))
b. 1 = [1]
m = 1
i = 2
while len(1)<3:
1.append(i)
m.append(1+1)
i = 1+1
c. 1 = range (17, 97)
while 1:
1 = = 1[20:-20]
✓ d. x = 100
while x>0:
S = 0
for x in range(100, -1, -1):
S = 5+1
༣
✓ f.
e.
1 = [1]
m = 1
i = 2
while m is 1:
1 = 1+[i]
m = 1+[i+1]
i = 1+1
f = lambda x: lambda y:
while f!=0:
f = f(0)
Expert Solution

This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
Step by step
Solved in 2 steps

Recommended textbooks for you

EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT

Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,

C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning

EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT

Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,

C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning

C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage

Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:
9781337102124
Author:
Diane Zak
Publisher:
Cengage Learning