` | |
---|---|
Backtick | |
In Unicode | U+0060`GRAVE ACCENT (symbol) |
Graphical variants | |
` | |
U+FF40`FULLWIDTH GRAVE ACCENT | |
Related | |
See also | U+0300◌̀ COMBINING GRAVE ACCENT (diacritic) |
The backtick` is a typographical mark used mainly in computing. It is also known as backquote, grave, or grave accent .
The character was designed for typewriters to add a grave accent to a (lower-case [a] ) base letter, by overtyping it atop that letter. [1] On early computer systems, however, this physical dead key+overtype function was rarely supported, being functionally replaced by precomposed characters. [b] Consequently, this ASCII symbol was rarely (if ever) used in computer systems for its original aim and became repurposed for many unrelated uses in computer programming.
The sign is located on the left-top of a US or UK layout keyboard, next to the 1 key. [c] On older keyboards, the Escape key was at this location, and the backtick key was somewhere on the right side of the layout. Provision (if any) of the backtick on other keyboards varies by national keyboard layout and keyboard mapping.
On typewriters designed for languages that routinely use diacritics (accent marks), there are two possible solutions. Keys can be dedicated to pre-composed characters or alternatively a dead key mechanism can be provided. With the latter, a mark is made when a dead key is typed but, unlike normal keys, the paper carriage does not move on and thus, the next letter to be typed is printed under the accent.
The incorporation of the grave symbol into ASCII is a consequence of this prior existence on typewriters. This symbol did not exist independently as a type or hot-lead printing character.
It appears to have been at their May 13–15, 1963 meeting that the CCITT decided that the proposed ISO 7-bit code standard would be suitable for their needs if a lower case alphabet and five diacritical marks, including the grave accent, were added to it. At the October 29–31 meeting, then, the ISO subcommittee altered the ISO draft to meet the CCITT requirements, replacing the up-arrow and left-arrow with diacriticals, adding diacritical meanings to the apostrophe and quotation mark, and making the number sign a dual for the tilde. [2]
— Yucca's free information site
Thus, ISO 646 was born and the ASCII standard updated to include the backtick and other symbols. [d]
Some early typewriters and ASCII peripherals designed the backtick and apostrophe to be mirror images of each other. [3] This allowed them to be used as matching pairs of open and close quotes, and also as grave and acute accents, and allowed the apostrophe to be used as a prime. None of these were considered typographically correct.
However, the use of apostrophe for opening quotes, the need on some typewriters to overprint apostrophe and period to get an exclamation mark, and the lack of a mirrored double-quote character tended to change the apostrophe to the modern "typewriter" design that is vertical. Unicode now provides separate characters for opening and closing quotes.
This has style remained in use in certain situations, such as in output generated by some UNIX console programs, rendering of man pages within some environments, and old technical documentation. This style is falling out of favor over time, and some institutions that traditionally used it have since abandoned it. [4] [5]
Many command-line interface languages and the scripting (programming) languages like Perl, PHP, Ruby and Julia (though see below) use pairs of backticks to indicate command substitution. A command substitution is the standard output from one command, into an embedded line of text within another command. [6] [7] For example, using $ as the symbol representing a terminal prompt, the code line:
$ echo"It is now `date`"It is now Wed Jan 1 19:11:30 UTC 2025
In all POSIX shells (including Bash and Zsh), the use of backticks for command substitution is now largely deprecated in favor of the notation $(...)
, so that the example above would be re-written:
$ echo"It is now $(date)"
The new syntax allows nesting, for example:
$ echo"An absolute path to the 'zcat' command is $(readlink-e"$(type-Pzcat)")"An absolute path to the 'zcat' command is /usr/bin/gzip
It is sometimes used in source code comments to indicate code, e.g.,
/* Use the `printf()` function. */
This is also the format the Markdown formatter uses to indicate code. [8] Some variations of Markdown support "fenced code blocks" that span multiple lines of code, starting (and ending) with three backticks in a row (```
). [9]
`
is rendered as single opening curly quote (‘) and ``
is a double curly opening quote (“). It also supplies the numeric ASCII value of an ASCII character wherever a number is expected.name
and pet
variable's values get substituted into the string enclosed by grave accent characters:constname="Mary",pet="lamb";// Set variableslettemp=`${name} has a little ${pet}!`;console.log(temp);// => "Mary has a little lamb!";
$
inside double quotes.Cmd
, that can be run, with run function, like run(`echo Hello world!`)
. You can interpolate Julia variables, but only indirectly shell environment variables.`n
. Most common programming languages use a backslash as the escape character (e.g., \n
), but because Windows allows the backslash as a path separator, it is impractical for PowerShell to use backslash for a different purpose. Two backticks produce the `
character itself. For example, the nullable boolean of .NET is specified in PowerShell as [Nullable``1[System.Boolean]]
.repr()
function, which converts its argument to a string suitable for a programmer to view. However, this feature was removed in Python 3.0. Backticks also appear extensively in the reStructuredText plain text markup language (implemented in the Python docutils package).In many PC-based computer games in the US and UK, the ` key is used to open the console so the user can execute script commands via its CLI. [ citation needed ] This is true for games such as Factorio , Battlefield 3 , Half-Life , Halo CE , Quake , Half-Life 2 , Blockland , Soldier of Fortune II: Double Helix , Unreal , Counter-Strike , Crysis , Morrowind , Oblivion , Skyrim , [13] Fallout: New Vegas , Fallout 3 , Fallout 4 , RuneScape , and games based on the Quake engine or Source engine. [ citation needed ] While not necessarily the original progenitor of the console key concept, Quake is still widely associated with any usage of the ` key as a toggle for a drop-down console, often being referred to as the "Quake Key". In 2021, Windows Terminal introduced a "Quake Mode" which enables a global shortcut of ⊞ Win+` that opens a terminal window pinned to the top half of the screen. [14]
ASCII, an acronym for American Standard Code for Information Interchange, is a character encoding standard for electronic communication. ASCII codes represent text in computers, telecommunications equipment, and other devices. ASCII has just 128 code points, of which only 95 are printable characters, which severely limit its scope. The set of available punctuation had significant impact on the syntax of computer languages and text markup. ASCII hugely influenced the design of character sets used by modern computers, including Unicode which has over a million code points, but the first 128 of these are the same as ASCII.
ISO/IEC 8859-1:1998, Information technology—8-bit single-byte coded graphic character sets—Part 1: Latin alphabet No. 1, is part of the ISO/IEC 8859 series of ASCII-based standard character encodings, first edition published in 1987. ISO/IEC 8859-1 encodes what it refers to as "Latin alphabet no. 1", consisting of 191 characters from the Latin script. This character-encoding scheme is used throughout the Americas, Western Europe, Oceania, and much of Africa. It is the basis for some popular 8-bit character sets and the first two blocks of characters in Unicode.
In computing, plain text is a loose term for data that represent only characters of readable material but not its graphical representation nor other objects. It may also include a limited number of "whitespace" characters that affect simple arrangement of text, such as spaces, line breaks, or tabulation characters. Plain text is different from formatted text, where style information is included; from structured text, where structural parts of the document such as paragraphs, sections, and the like are identified; and from binary files in which some portions must be interpreted as binary objects.
QWERTY is a keyboard layout for Latin-script alphabets. The name comes from the order of the first six keys on the top letter row of the keyboard: QWERTY. The QWERTY design is based on a layout included in the Sholes and Glidden typewriter sold via E. Remington and Sons from 1874. QWERTY became popular with the success of the Remington No. 2 of 1878 and remains in ubiquitous use.
In computing and telecommunications, an escape character is a character that invokes an alternative interpretation on the following characters in a character sequence. An escape character is a particular case of metacharacters. Generally, the judgement of whether something is an escape character or not depends on the context.
The tilde is a grapheme ⟨˜⟩ or ⟨~⟩ with a number of uses. The name of the character came into English from Spanish tilde, which in turn came from the Latin titulus, meaning 'title' or 'superscription'. Its primary use is as a diacritic (accent) in combination with a base letter. Its freestanding form is used in modern texts mainly to indicate approximation.
A carriage return, sometimes known as a cartridge return and often shortened to CR, <CR>
or return, is a control character or mechanism used to reset a device's position to the beginning of a line of text. It is closely associated with the line feed and newline concepts, although it can be considered separately in its own right.
A newline is a control character or sequence of control characters in character encoding specifications such as ASCII, EBCDIC, Unicode, etc. This character, or a sequence of characters, is used to signify the end of a line of text and the start of a new one.
The pound sign is the symbol for the pound unit of sterling – the currency of the United Kingdom and its associated Crown Dependencies and British Overseas Territories and previously of Great Britain and of the Kingdom of England. The same symbol is used for other currencies called pound, such as the Egyptian and Syrian pounds. The sign may be drawn with one or two bars depending on personal preference, but the Bank of England has used the one-bar style exclusively on banknotes since 1975.
PETSCII, also known as CBM ASCII, is the character set used in Commodore Business Machines' 8-bit home computers.
The Alt keyAlt on a computer keyboard is used to change (alternate) the function of other pressed keys. Thus, the Alt key is a modifier key, used in a similar fashion to the Shift key. For example, simply pressing A will type the letter 'a', but holding down the Alt key while pressing A will cause the computer to perform an Alt+A function, which varies from program to program. The international standard ISO/IEC 9995-2 calls it Alternate key. The key is located on either side of the space bar, but in non-US PC keyboard layouts, rather than a second Alt key, there is an 'Alt Gr' key to the right of the space bar. Both placements are in accordance with ISO/IEC 9995-2. With some keyboard mappings, the right Alt key can be reconfigured to function as an AltGr key although not engraved as such.
Backspace is the keyboard key that in typewriters originally pushed the carriage one position backwards, and in modern computer systems typically moves the display cursor one position backwards, deletes the character at that position, and shifts back any text after that position by one character.
On computer keyboards, the enter key⌅ Enter and return key↵ Return are two closely related keys with overlapping and distinct functions dependent on operating system and application.
The hyphen-minus symbol - is the form of hyphen most commonly used in digital documents. On most keyboards, it is the only character that resembles a minus sign or a dash so it is also used for these. The name hyphen-minus derives from the original ASCII standard, where it was called hyphen (minus). The character is referred to as a hyphen, a minus sign, or a dash according to the context where it is being used.
A typographic approximation is a replacement of an element of the writing system with another glyph or glyphs. The replacement may be a nearly homographic character, a digraph, or a character string. An approximation is different from a typographical error in that an approximation is intentional and aims to preserve the visual appearance of the original. The concept of approximation also applies to the World Wide Web and other forms of textual information available via digital media, though usually at the level of characters, not glyphs.
The German keyboard layout is family of QWERTZ keyboard layouts commonly used in Austria and Germany. It is based on one defined in a former edition of the German standard DIN 2137–2. The current edition DIN 2137-1:2012-06 standardizes it as the first (basic) one of three layouts, calling it "T1".
The Vietnamese language is written with a Latin script with diacritics which requires several accommodations when typing on phone or computers. Software-based systems are a form of writing Vietnamese on phones or computers with software that can be installed on the device or from third-party software such as UniKey. Telex is the oldest input method devised to encode the Vietnamese language with its tones. Other input methods may also include VNI and VIQR. VNI input method is not to be confused with VNI code page.
Caret is the name used familiarly for the character ^ provided on most QWERTY keyboards by typing ⇧ Shift+6. The symbol has a variety of uses in programming and mathematics. The name "caret" arose from its visual similarity to the original proofreader's caret, ‸, a mark used in proofreading to indicate where a punctuation mark, word, or phrase should be inserted into a document. The ASCII standard (X3.64.1977) calls it a "circumflex"; the Unicode standard calls it a "circumflex accent", although it is no longer practicable for that purpose.
The Italian keyboard layout is the keyboard layout commonly used on computers in Italy. It is QWERTY-based and follows the ISO/IEC 9995 standard. Italian-speaking people in Switzerland on the contrary use the Swiss QWERTZ keyboard with Swiss Italian layout.
This key is on German typewriters a non-spacing key (DIN 2137). It does not advance the cursor, but causes the next character to appear below the accent
Please do not use the ASCII grave accent as a left quotation mark
In the C locale, the output of GNU programs should stick to plain ASCII for quotation characters in messages to users: preferably 0x22 (‘"’) or 0x27 (‘'’) for both opening and closing quotes. Although GNU programs traditionally used 0x60 (‘`’) for opening and 0x27 (‘'’) for closing quotes, nowadays quotes ‘`like this'’ are typically rendered asymmetrically, so quoting ‘"like this"’ or ‘'like this'’ typically looks better.