May 2019
Beginner to intermediate
466 pages
10h 44m
English
However, escaping can get messy, so there's a much better way of dealing with this—by using triple quotes """...""".
julia> """Beta is Latin for "still doesn't work"."""
Within triple quotes, it is no longer necessary to escape the single quotes. However, make sure that the single quotes and the triple quotes are separated—or else the compiler will get confused:
julia> """Beta is Latin for "still doesn't work"""" syntax: cannot juxtapose string literal
The triple quotes come with some extra special powers when used with multiline text. First, if the opening """ is followed by a newline, this newline is stripped from the string. Also, whitespace is preserved but the string is dedented to the level of the least-indented ...
Read now
Unlock full access