Vidyalelo
Python · Q46

Regular Expressions in Python

Programming · Python · question 46

Q46

What is the purpose of the re.sub() function in Python?

A.
It replaces occurrences of a pattern with a specified string
Answer
B.
It converts strings to regular expressions
C.
It searches for a match anywhere in the string
D.
It checks if a string contains a specific character

Answer: Option A

Solution

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