Skip to content

Latest commit

 

History

History
21 lines (14 loc) · 428 Bytes

File metadata and controls

21 lines (14 loc) · 428 Bytes

Count characters of a string in Julia

Code points

The core length function returns the number of code points when called on a string.

count = length(str)

Grapheme clusters

The UnicodeExtras module provides the length function, which returns the number of grapheme clusters when called on a string.

using UnicodeExtras

count = length(str)