Some of the special symbols that are used in C programming are as follows −
[] () {}, : ; * = #
Let’s understand their definitions, which are as follows −
Brackets[] − Opening and closing of brackets are used for array element reference, which indicate single and multidimensional subscripts.
Parentheses() − These special symbols are used for function calls and function parameters (Read: Functions in C).
Braces{} − Opening and closing of curly braces indicates the start and end of a block of code which contains more than one executable statement.
Comma (, ) − It is used to separate more than one statements like separating parameters in function calls.
Colon(:) − It is an operator which essentially invokes something called as an initialization list.
Semicolon(;) − It is called as a statement terminator that indicates the end of one logical entity. That is the reason each individual statement must be ended with a semicolon.
Asterisk (*) − It is used to create a pointer variable.
Assignment operator(=) − It is used for assigning values.
Pre-processor (#) − The pre-processor called as a macro processor is used by the compiler to transform your program before the actual compilation starts.
| Symbol | Meaning |
|---|---|
| ~ | Tilde |
| ! | Exclamation Mark/td> |
| # | Number Sign |
| $ | Dollar Sign |
| % | Percent sign CaretAmpersand |
| ^ | Caret |
| & | Ampersand |
| * | Asterisk |
| () | Parenthesis Left Parenthesis Right |
| _ | Underscore |
| + | Plus Sign |
| , | Comma |
| . | Period |
| / | Slash |
| | | Vertical bar |
| ` | Apostrophe |
| \ | Backslash |
| - | Minus Sign |
| = | Equal to sign |
| <> | Opening Angle Bracket Closing Angle Bracket |
| ? | Question Mark |
| {} | Left Brace Right Brace |
| [] | Left Bracket Right Bracket |
| : | Colon |
| " | Quotation Mark |
| ; | Semicolon |
Tidak ada komentar:
Posting Komentar