Keywords
The following list shows the reserved words in C. These reserved words may not be used as constant or variable or any other identifier names.
| auto | else | long | switch |
| break | enum | register | typedef |
| case | extern | return | union |
| char | float | short | unsigned |
| const | for | signed | void |
| continue | goto | sizeof | volatile |
| default | if | static | while |
| do | int | struct | _Packed |
| double |
White space
A line containing only white space, possibly with a comment, is known as a blank line, and a C compiler totally ignores it.
White space is the term used in C to describe blanks, tabs, newline characters and comments. White space separates one part of a statement from another and enables the compiler to identify where one element in a statement, such as int, ends and the next element begins. Therefore, in the following statement:
int age;
There must be at least one white space character (usually a space) between int and age for the compiler to be able to distinguish them. On the other hand, in the following statement:
fruit = apples + oranges; // get the total fruit
No white space characters are necessary between fruit and =, or between = and apples, although you are free to include some if you wish for readability purpose.
No comments:
Post a Comment