Take a look at the code below. How can you get a tuple containing the matches for groups? Write the command in the answer line.
template = "Green Day - ([\w\s]+), (200\d)"
result = re.match(template, "Green Day - Whatsername, 2004")Take a look at the code below. How can you get a tuple containing the matches for groups? Write the command in the answer line.
template = "Green Day - ([\w\s]+), (200\d)"
result = re.match(template, "Green Day - Whatsername, 2004")Create a free account to access the full topic