Skip to content

Instantly share code, notes, and snippets.

@dionisos2
Last active April 13, 2019 18:54
Show Gist options
  • Save dionisos2/0ebab561699b657a3144f225cbe95fdb to your computer and use it in GitHub Desktop.
Save dionisos2/0ebab561699b657a3144f225cbe95fdb to your computer and use it in GitHub Desktop.
julia> io = IOBuffer("JuliaLang");
julia> string(io.data)
"UInt8[0x4a, 0x75, 0x6c, 0x69, 0x61, 0x4c, 0x61, 0x6e, 0x67]"
julia> string(io.data)
"UInt8[0x4a, 0x75, 0x6c, 0x69, 0x61, 0x4c, 0x61, 0x6e, 0x67]"
julia> String(io.data)
"JuliaLang"
julia> String(io.data)
""
julia> read(io, Char)
'J': ASCII/Unicode U+004a (category Lu: Letter, uppercase)
julia> read(io, Char)
'u': ASCII/Unicode U+0075 (category Ll: Letter, lowercase)
julia> read(io, Char)
'l': ASCII/Unicode U+006c (category Ll: Letter, lowercase)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment