Home »
Python »
Python List MCQs
What will be the outcome?
27. What will be the outcome?
# Suppose you have the following list
l1=["include help","hello","everyone",1,2,[1000,123]]
print(l1.index("hello"))
- 0
- 1
- 2
- 3
Answer: B) 1
Explanation:
The index function will give you the index of the particular element.