Skip to content

StringFreeQ

StringFreeQ("string", patt)

returns True if no substring in string matches the string expression patt, and returns False otherwise.

StringFreeQ({"s1", "s2", ...}, patt)

returns the list of results for each element of the string list.

StringFreeQ("string", {p1, p2, ...})

returns True if no substring matches any of the pi.

StringFreeQ(patt)

represents an operator form of StringFreeQ that can be applied to an expression.

See

Examples

>> StringFreeQ("symja", "s" ~~__ ~~"a")
False
>> StringFreeQ("symja", "y" ~~__~~"s")
True
>> StringFreeQ("Symja", "SY" ,IgnoreCase -> True)", //
False
>> StringFreeQ({"g", "a", "laxy", "universe", "sun"}, "u")
{True,True,True,False,False}
>> StringFreeQ("e" ~~___ ~~"u") /@ {"The Sun", "Mercury", "Venus", "Earth", "Mars", "Jupiter", "Saturn", "Uranus", "Neptune"}
{False,False,False,True,True,True,True,True,False}
>> StringFreeQ({"A", "Galaxy", "Far", "Far", "Away"}, {"F" ~~__ ~~"r", "aw" ~~___}, IgnoreCase ->True)
{True,True,False,False,False}

StringCases, StringContainsQ, StringCount, StringExpression, StringInsert, StringJoin, StringLength, StringMatchQ, StringPart, StringPosition, StringQ, StringReplace, StringRiffle, StringSplit, StringTake, StringToByteArray, StringTrim

Implementation status

  • ✅ - full supported

Github