A string literal is the representation of a string value within the source code of a computer program. There are numerous alternate notations for specifying string literals, and the exact notation depends on the individual programming language in question. Nevertheless, there are some general guidelines that most modern programming languages follow.
Specifically, most string literals can be specified using:
- declarative notation;
- whitespace delimiters (indentation);
- bracketed delimiters (quoting);
- escape characters; or
- a combination of some or all of the above
Read more about String Literal: Declarative Notation, Whitespace Delimiters, Bracketed Delimiters, Delimiter Collision, Metacharacters, Variable Interpolation, Binary and Hexadecimal Strings, Embedding Source Code in String Literals
Famous quotes containing the words string and/or literal:
“Amongst the learned the lawyers claim first place, the most self-satisfied class of people, as they roll their rock of Sisyphus and string together six hundred laws in the same breath, no matter whether relevant or not, piling up opinion on opinion and gloss on gloss to make their profession seem the most difficult of all. Anything which causes trouble has special merit in their eyes.”
—Desiderius Erasmus (c. 14661536)
“The literal alternatives to [abortion] are suicide, motherhood, and, some would add, madness. Consequently, there is some confusion, discomfort, and cynicism greeting efforts to find or emphasize or identify alternatives to abortion.”
—Connie J. Downey (b. 1934)