Source Code:
(back to article)
def is_substring(string, string_list): return any(string in s for s in string_list) string_list = ["hallo", "welt", "tschüss"] print(is_substring("wel", string_list)) # True print(is_substring("hund", string_list)) # False
Result:
Report an issue