HasPunctuation - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


StringTools

  

HasPunctuation

  

determine if a string contains a punctuation character

 

Calling Sequence

Parameters

Description

Thread Safety

Examples

Calling Sequence

HasPunctuation(s)

Parameters

s

-

string; string to test

Description

• 

The HasPunctuation( s ) command determines whether s contains a punctuation character. Punctuation characters are printable characters, other than whitespace, for which neither IsControlCharacter nor IsAlphaNumeric returns true.

• 

If s contains a punctuation character, HasPunctuation returns true. Otherwise, false is returned.

• 

All of the StringTools package commands treat strings as (null-terminated) sequences of 8-bit (ASCII) characters.  Thus, there is no support for multibyte character encodings, such as unicode encodings.

Thread Safety

• 

The StringTools[HasPunctuation] command is thread-safe as of Maple 15.

• 

For more information on thread safety, see index/threadsafe.

Examples

withStringTools:

HasPunctuationabcde

false

(1)

HasPunctuationabc,de

true

(2)

See Also

convert

length

string

StringTools

StringTools[IsAlphaNumeric]

StringTools[IsControlCharacter]

StringTools[IsPunctuation]