2019-12-12 23:02:49 +00:00
|
|
|
from typing import *
|
|
|
|
import re
|
|
|
|
|
|
|
|
|
2019-12-13 01:48:16 +00:00
|
|
|
def any_in_string(patterns: Collection[str], string: str) -> bool:
|
2019-12-12 23:02:49 +00:00
|
|
|
for pattern in patterns:
|
|
|
|
if re.search(pattern, string):
|
|
|
|
return True
|
|
|
|
return False
|