Bracket Article Index for
Bracket
Articles about
Bracket
Website Links For
Bracket
 

Information About

Bracket




For technical reasons,


Brackets are Punctuation marks used in pairs to set apart or interject text within other text. With respect to Computer Science , the term is sometimes said to only strictly apply to the square or box type. Free Online Dictionary of Computing

There are four main types of brackets:
  • parentheses or '''round brackets''':  ( )

  • box brackets or '''square brackets''':   {Link without Title}

  • curly brackets or '''braces''':  { }

  • angle brackets or '''chevrons''': < >


All these forms may be used according to Typographical conventions that may vary from publication to publication and may vary even more from language to language. Some typical uses in English texts follow.


USAGE

In addition to referring to the class of all types of brackets, the unqualified word ''bracket'' is most commonly used to refer to a specific type of bracket. In modern American usage this is usually the square bracket, whereas in modern British usage it is usually the parenthesis (round bracket).

In American usage, parentheses are usually considered separately from other brackets, and calling them "brackets" at all is unusual, even though they serve a similar function. In more formal usage, "parenthesis" may refer to the entire bracketed text, not just to the punctuation marks used {so all the text in this curly bracket may be said to be a parenthesis}.


Types of brackets


Parentheses ( )

Parentheses (singular '''parenthesis''')—sometimes called '''round brackets''', '''curved brackets''', '''oval brackets''', or just '''brackets'''; or, colloquially, '''parens''', or '''fingernails'''— contain material that could be omitted without destroying or altering the meaning of a sentence.

In formal writing, parentheses may be used to add supplementary information, such as "Sen. Edward Kennedy (D., Massachusetts) spoke at length." They can also indicate shorthand for "either singular or plural" for nouns—e.g., "the claim(s)".

In literature and informal writing, parenthetical phrases have been used extensively in stream of consciousness literature. Of particular note is the southern American author ). In most writing, overuse of parentheses is usually a sign of a badly structured text. A milder effect may be obtained by using a pair of commas as the Delimiter . If the sentence contains commas for other purposes, visual confusion may result.

Historically, parentheses have been used where the Slash is currently used—that is, in order to depict alternatives, such as "parenthesis)(parentheses". Examples of this usage can be seen in editions of '' Fowler’s ''.

Parentheses may also be nested (with one set (such as this) inside another set). This is not commonly used in formal writing (though sometimes other brackets square brackets will be used for one or more inner set of parentheses other words, ''secondary'' {or even ''tertiary''} phrases can be found within the main sentence ).

Any punctuation inside parentheses or other brackets is independent from the rest of the text: "Mrs. Pennyfarthing (What? Yes, that was her name!) was my landlady". In this usage, the explanatory text in the parentheses is a Parenthesis . (It is most common for the parenthesized text to be within a single sentence, but not uncommon for an entire sentence, or even several sentences, of supplemental material to be in parenthesis. In this case, even the final Full Stop would be within the parentheses. Again, the parenthesis implies that the meaning and flow of the text as a whole would be unchanged were the parenthesized sentences removed.)

In .

]]


Box brackets or square brackets


Square brackets enclose explanatory or missing material, especially in quoted text. For example, "I appreciate it [the honor , but I must refuse". Or, "the future of Psionics definition is in doubt".

The bracketed expression (Latin for "thus") is used to indicate errors that are "thus in the original"; a bracketed Ellipsis [... is often used to indicate deleted material; bracketed comments indicate when original text has been modified for clarity: "I'd like to thank unimportant people and my parentals for their love, tolerance [... and ''assistance'' added'' ".

In Mathematics , square brackets are used in a variety of notations, including standard notations for Intervals , Commutator s, the Lie Bracket , and the Iverson Bracket .

Square brackets are also sometimes used as parentheses within parentheses (alternating between parentheses and square brackets according to nesting level, curly braces are often used instead for deeper nesting (as mentioned earlier) ).

With the International Phonetic Alphabet , square brackets indicate a Phonetic transcription (as opposed to a Phonemic one).

In Chemistry , square brackets can also be used to represent the Concentration of a Chemical Substance , or to denote a Complex Ion .

In Architecture , square brackets can be used to emphasize Cool words, such as or [cityscape . It can also be used to make the layout generally look more cool and modern.

In Proofreading , square brackets (called ''move-left symbols'' or ''move right symbols'') are added to the sides of text to indicate changes in indentation:

  { Align "left"
  Width "15%"
  { Align "left"
  Width "85%"
  { Align "left"
  Width "15%"
  { Align "left"
  Width "85%"
  { Align "left"





Angle brackets are infrequently used to denote dialogue that is thought instead of spoken, such as:

:

In Linguistics , angle brackets indicate Orthography , as in "The English word is spelled cat."

In Textual Criticism , and hence in many editions of poorly transmitted works, angle brackets denote sections of the text which are illegible or otherwise lost; the editor will often insert his own reconstruction where possible within them.

Single and double angle brackets () or pairs of the appropriate comparison operators (<<, >>) are sometimes used instead of Guillemets (, ) (used as Quotation Mark s in many languages) when the proper Glyph s are not available.

The mathematical or logical symbols for greater-than (>) and less-than (<) are Inequality operators, and when used as such, are not punctuation marks.

, and and or and for Horizontal printing.

In Comic Book s, angle brackets are often used to mark dialogue that has notionally been translated from another language.

Angle brackets can also be used to indicate an action or status (eg. or ), particularly in online, real-time text-based discussions (instant messaging, bulletin boards, etc). (Here, asterisks can also be used to signify an action.)


IN COMPUTING


  • Opening and closing parentheses correspond to ASCII and Unicode Character s 40 and 41, or 0x 0028 and 0x0029, respectively.

  • For square brackets corresponding values are 91 and 93, or 0x005B and 0x005D.

  • For braces, 123 and 125, or 0x007B and 0x007D.

  • True angle brackets are available in Unicode at code points 0x27e8 and 0x27e9 (for mathematical use), or 0x9001 and 0x9002 (for East Asian languages), or 0x2329 and 0x232A (for "technical" use, canonically equivalent to the CJL code points 0x900x). The less than and greater than symbols can be found in both Unicode and ASCII at code points 60 and 62, or 0x003C and 0x003E.


Also, in many Computer Language s:

  • "(" and ")"

  • --- are often used to define the syntactic structure of expressions, overriding Operator Precedence : a---(b+c) has subexpressions a and b+c, whereas a---b+c has subexpressions a---b and c.

  • --- contain the arguments to functions: substring(,10,1). On the other hand, in -family languages, they are also used for array references.

  • --- in the Perl programming language, they are used to define ''lists'', static array-like structures; this idiom is extended to their use as containers of subroutine (function) arguments

  • " and " "

  • --- refer to array or Associative Array elements, and sometimes to define the number of elements in an array: queue {Link without Title} .

  • --- in Perl, they create anonymous arrays and refer to array elements as above.

  • --- in most Regular Expression syntaxes square brackets denote a character class: a series of possible characters to choose from.

  • --- are often used in functional languages (such as Standard ML ) for list literals.

  • "{" and "}"

  • --- are used in some languages to define the beginning and ending of Blocks of code. Languages which use this convention are said to belong to the Curly Brace Family of programming languages.

  • --- denote array Constant s.

  • --- in the Pascal Programming Language , they define the beginning and ending of comments.

  • --- in most Regular Expression syntaxes, they are used as quantifiers, matching ''n'' repetitions of the previous group.

  • --- in Perl, they create anonymous Associative Arrays and refer to associative array elements.

  • "<" and ">"

  • --- in SGML (and its applications and variants such as HTML and XML ), used to enclose code tags: <div>

  • --- in Java , C++ and C# , used to delimit Generic Arguments and Preprocessor directives.

  • --- in Perl, used to read a line from an input source.

  • --- also used as operators for Redirection in Unix' and other operating systems' shells. In this context, they are often referred to as hoinkies (singular '''hoinky''') in order to "avoid confusion with other bracket-type operators".



Layout styles

In normal text an opening bracket is not put at the end of a line, and a closing bracket not at the beginning. However, in computer code this is often done to aid readability. For example, a bracketed list of items separated by semicolons may be written with the brackets on separate lines, and the items, followed by the semicolon, each on one line.

For example, the CSS code

h1 { font-weight: bold; font-size: 12pt; line-height: 14pt }

may also be written

h1 {
font-weight: bold;
font-size: 12pt;
line-height: 14pt
}

See Indent Style .


IN MATHEMATICS

See Also: Bracket (mathematics)


In addition to the use of Parentheses to specify the Order Of Operations , both parentheses and square brackets are used to denote an Interval . The notation [a, c) is used to indicate an interval from ''a'' to ''c'' that is inclusive of ''a'' but exclusive of ''c''. That is, [5, 12) would be the set of all real numbers between 5 and 12, including 5 but not 12. The numbers may come as close as they like to 12, including 11.999 and so forth (with any Finite number of 9s), but 12.0 is not included. (In Europe, the notation [5,12[ is also used for this.) The endpoint adjoining the square bracket is known as ''closed'', while the endpoint adjoining the parenthesis is known as ''open''. If both types of brackets are the same, the entire interval may be referred to as ''closed'' or ''open'' as appropriate. Whenever Infinity or negative infinity is used as an endpoint, it is always considered ''open'' and adjoined to a parenthesis. See Interval (mathematics) for a more complete treatment.

  Last Bryant
  First Randal E
  Author-link Randal Bryant
  Last2 David
  First2 O'Hallaron
  Title Computer Systems: A Programmer's Perspective
  Place Upper Saddle River, NJ
  Publisher Pearson Education
  Year 2003
  Edition 2003
  Pages 794
  Url http://csappcscmuedu/
  Isbn 0-13-034074-X