Macaulay2 » Documentation
Packages » Macaulay2Doc :: characters
next | previous | forward | backward | up | index | toc

characters -- get characters from a string

Synopsis

Description

The characters are represented by strings.

i1 : characters "asdf"

o1 = {a, s, d, f}

o1 : List

utf8 characters are correctly treated:

i2 : characters "π ≈ 3.14159"

o2 = {π,  , ≈,  , 3, ., 1, 4, 1, 5, 9}

o2 : List

To get the one-byte characters of the string, use toList instead.

See also

For the programmer

The object characters is a compiled function.