C Programming Reference


C Programming Reference >> C Basic Tutorials >> C Keywords Home >>

typedef

30/12/06 -  Views - Ratings :   3.48 of 5 / 155 Votes

Using typedef you define new names of exisiting data types. This does not create a new physical datatype but is simply new name of calling existing typedef. Typedef helps in making code portable and more readable.

Code -
typedef int A;
typedef A B;
void function (void)
{
A a = 10;
B b; \\ A and B both created an int variable.

}

Back To Top


      

 

 

© 2006 cencyclopedia.com