单选题

下⾯的描述中,(  )不能正确定义⼀个名为 Student 的结构体以及⼀个包含20个元素的结构数组。

A.

struct Student { 

     string name;

     int age; float score; 

 };

 struct Student  students[20];

B.

struct Student { 

     string name; 

     int age;

     float score; 

 }; 

 Student  students[20];

C.

struct Student { 

     string name;

     int age; 

     float score;

 }; 

 Student*  students = new Student[20];

D.

struct Student {

     string name;

     int age; 

     float score; 

 };

 Student  students = new Student[20];

发表评论

登录 后再回复