Structures II (Typedef, Array & Nested)
Structures II (Typedef, Array & Nested)
Computer Programming
struct motor {
float volts;
float amps;
float rpm;
unsigned int phases;
}; //struct motor
3
Typedef
• Typedef is a keyword that is used to give a new
symbolic name for the existing name in a C program.
This is same like defining alias for the commands.
E.g.,
typedef struct motor Motor;