published: 2nd of August 2021
# Define a string.
stuff = "stuff"
# Multi-line string.
stuff_and_things="stuff
and
things"
# Define a symbol.
stuff = :stuff
# Define a symbol enclosed in double quotes.
# This allows for a space in the symbol.
things = :"my things"
# Symbols are a good options for hash keys.
stuff_and_things = {
:stuff => "my stuff",
:things => "my things"
}
https://pragprog.com/titles/crystal/programming-crystal/
https://crystal-lang.org/reference/syntax_and_semantics/literals/string.html
https://crystal-lang.org/reference/syntax_and_semantics/literals/symbol.html