
1. Please complete the following code:
fruit = ["Apple", "Orange"]
num = [10, 20]
for x in fruit:
print(x, y)
Sample Output:
Apple 10
Apple 20
Orange 10
Orange 20
Questions include multiple choice, fill-in questions and coding project.
fruit = ["Apple", "Orange"]
num = [10, 20]
for x in fruit:
print(x, y)
Sample Output:
Apple 10
Apple 20
Orange 10
Orange 20
myNum = [10, 20, 30, 40, 50, 60, 70, 80]
Sample Output:
80
[30, 40, 50, 60]
[30, 50]
for x in range(1, 10, 2):
Sample Output:
1 @ 3 @ 5 @ 7 @ 9 @
numList=[10, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60, 65, 70]
for x in numList:
if (x > 50): if(x % 10 == 0):
Sample Output:
10
20
30
40
50