string.containsAny

This function reports whether any Unicode code points in characters exist within the input settings.

Syntax

string.containsAny(str, substr)

Arguments

Argument

Type

Description

str

string

Source string

substr

string

Substring to be searched for in the source string

Returns

Type

Description

boolean

  • True: if the substring exists in the source string
  • False: if the substring does not exist in the source string

Examples

The function string.containsAny("Seafood", "food") returns true.