Content deleted Content added
→String literals: Put more capable syntaxes first, which will hopefully deter people from adding syntaxes to sections that don't reflect their full capabilities |
m →String literals: Forgot to move a section |
||
Line 124:
| <tt>!"I said \"Hello, world!\""</tt>
| FreeBASIC
|}▼
=== Dual quoting ===▼
"Dual quoting" means that whenever a quote is used in a string, it is used twice, and one of them is discarded and the single quote is then used within the string.▼
<!-- Before you add your favorite language to this table, make sure it's not listed in another section. -->▼
{| class="wikitable"▼
|-▼
! Syntax▼
! Language(s)▼
|-▼
| <tt>"I said ""Hello, world!"""</tt>▼
| Ada, ALGOL 68, Excel, Fortran, Visual Basic, FreeBASIC, COBOL▼
|-▼
| <tt><nowiki>'I said ''Hello, world!'''</nowiki></tt>▼
| Fortran, rc, COBOL, SQL, Pascal, Object Pascal, APL, Smalltalk▼
|}
Line 151 ⟶ 166:
| <tt>R"(Hello, world!)"</tt>
| C++11
▲|}
▲=== Dual quoting ===
▲"Dual quoting" means that whenever a quote is used in a string, it is used twice, and one of them is discarded and the single quote is then used within the string.
▲<!-- Before you add your favorite language to this table, make sure it's not listed in another section. -->
▲{| class="wikitable"
▲|-
▲! Syntax
▲! Language(s)
▲|-
▲| <tt>"I said ""Hello, world!"""</tt>
▲| Ada, ALGOL 68, Excel, Fortran, Visual Basic, FreeBASIC, COBOL
▲|-
▲| <tt><nowiki>'I said ''Hello, world!'''</nowiki></tt>
▲| Fortran, rc, COBOL, SQL, Pascal, Object Pascal, APL, Smalltalk
|}
|