Vidyalelo
Python · Q87

Regular Expressions in Python

Programming · Python · question 87

Q87

What will be the output of the following Python code? re.sub('morning', 'evening', 'good morning')

A.
'good evening'
Answer
B.
'good'
C.
'morning'
D.
'evening'

Answer: Option A

Solution

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