Differentiate between for loop and while loop with program example.
For loop is used when number of iteration is known. eg :
``` for (int i=0;i<n;i++){
}
```
Incase if while loop , it runs till the condition is true. eg:
```
while(n>0){
}
```
Structures in C is a user-defined data type available in C that allows to combining of data items of different kinds. Structures are used to represent a record.
Defining a structure: To define a structure, you must use the struct statement. The struct statement defines a new data type, with more than or equal to one member. The format of the struct statement is as follows:
struct [structure name] { member definition; member definition; ... member definition;...