regex rf code example Example: re.search variable if re.search(rf"\b(?=\w){TEXTO}\b(?!\w)", subject, re.IGNORECASE): ...do something