You can create your own names for data types with the help of the typedef keyword in C, and use those names as
synonyms for the data types. For instance, you can declare TWO_BYTE as a synonym for the int data type:
typedef int TWO_BYTE;
Then, you can use TWO_BYTE to declare integer variables like this,
TWO_BYTE i, j;
which is equivalent to
int i, j;
Remember that a typedef definition must be made before the synonym made in the definition is used in any
declarations in your program.
Friday, October 16, 2009
Subscribe to:
Post Comments (Atom)

No comments:
Post a Comment