Vidyalelo
Python · Q55

Regular Expressions in Python

Programming · Python · question 55

Q55

How can you replace a matched pattern with a new string using regular expressions in Python?

A.
By using the sub() function from the re module
Answer
B.
By using the replace() function
C.
By using the new() function
D.
By using the replace keyword

Answer: Option A

Solution

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