Previous | Home | Next |
C Keywords
The meaning of keywords has already been explained to the C compiler. The key word ‘cannot’ be used as variable name because if we do so we are trying to assign new meaning to the keyword, which is not allowed by the computer.
The keywords are also called 'Reserved Words'
There are 32 keywords used in C language. which are:
auto | case | float | goto |
double | enum | short | sizeof |
int | register | unsigned | volatile |
struct | typedef | continue | do |
break | char | for | if |
else | extern | signed | static |
long | return | void | while |
switch | union | default | const |
Data type modifiers in C
- long-Forces a type int to be 4 bytes (32 bits) long and forces a typebdouble to be larger than a double (but the actual size is implementation defined). Cannot be used with short.
- short- short Forces a type int to be 2 bytes (16 bits) long. Cannot be used with long.
- unsigned- unsigned Causes the compiler (and CPU) to treat the number as containing only positive values. Because a 16-bit signed integer can hold values between -32,768 and 32,767, an unsigned integer can hold values between 0 and 65,535. The unsigned modifier can be used with char, long, and short (integer) types.
Previous | Home | Next |