Regex solution in Creative category for Find Quotes by Rcp8jzd
import re def find_quotes(a): # Some explanations: the .* matches any character inside quotes # The ? character indicates that the expression is non-greedy: # For example, if RE <.*> is matched against ' b ', it will match the # entire string, and not just . Adding ? after the qualifier makes it # perform the match in non-greedy or minimal fashion; as few characters as # possible will be matched. Using the RE <.*?> will match only ''. # The parenthesis indicates that we only want what's inside quotes, without # quotes. return re.findall(r'"(.*?)"', a)
March 29, 2020
Comments: