startsWith


Description:

public static bool startsWith (string? s, string? prefix)

Returns whether the string starts with the specified prefix.

Example:

    assert (Strings.startsWith ("HelloWorld", "Hello") == true);
assert (Strings.startsWith ("HelloWorld", "World") == false);

Parameters:

s

the string to check.

prefix

the prefix.

Returns:

true if s starts with prefix.