Write the different methods of structure initialization.
A struct variable can be initialized, like any other data variables in C++, at the time it is declared. We could use:
struct student
{
char name[20];
int regno;
float fees;
}
s1 = {“ram”, 25,24000.50};
or
student s1 = {“ram”, 25,24000.50};