Vidyalelo
Python · Q90

Python Loops and Conditionals: MCQs for Exam Readiness

Programming · Python · question 90

Q90

What will be the output of the following Python code? x = ['ab', 'cd'] for i in x: i.upper() print(x)

A.
['ab', 'cd']
Answer
B.
['AB', 'CD']
C.
[None, None]
D.
none of the mentioned

Answer: Option A

Solution

Answer: Option A
No explanation is given for this question Let's Discuss on Board