Structure Declaration in C

The first way is to declare a structure variable immediately after the structure definition, as follows: struct address { int house_number; char street_name[50]; int zip_code; char country[50]; } struct_var1, struct_var2; In the second way, you can declare the structure variable at a different location after structure definition. Here is structure declaration syntax: struct address { … Read more

Arrays in C

Imagine that you have to store and later retrieve the unique ID of all of the registered voters in your city. Yes, you can create and name hundreds of thousands of distinct variable names to store the information. However, that would scatter hundreds of thousands of names all over memory. In addition, there is a … Read more