234k views
0 votes
Write a code to define a structure named student, which includes name, student number and email address

1 Answer

3 votes

Answer:

Hi!

I will write the code on C.

struct student //define the struct on C.

{

char name[50]; //define an array of char for name.

int number[15] ; //define an array of int for number.

char email[50]; //define an array of char for email adress.

}

Step-by-step explanation:

The general syntax for structure in C is:

struct structName

{

data-type structMember1;

data-type structMember2;

data-type structMember3;

data-type structMember4;

};

User Ashwini Verma
by
4.7k points