utf8bytelength: count UTF8 string bytelength
[Builtin name changed, and it only works on string inputs. -Nico]
This commit is contained in:
1 parent
63dd033da7
commit
83e8ec587f
3 files changed
+28
No files matched your search
@@ -662,6 +662,18 @@ sections:
|
||||
input: '[[1,2], "string", {"a":2}, null]'
|
||||
output: [2, 6, 1, 0]
|
||||
|
||||
|
||||
- title: "`utf8bytelength`"
|
||||
body: |
|
||||
|
||||
The builtin function `utf8bytelength` outputs the number of
|
||||
bytes used to encode a string in UTF-8.
|
||||
|
||||
examples:
|
||||
- program: 'utf8bytelength'
|
||||
input: '"\u03bc"'
|
||||
output: [2]
|
||||
|
||||
- title: "`keys`, `keys_unsorted`"
|
||||
body: |
|
||||
|
||||
|
||||
Reference in new issue
Block a user