PROGRAMMING:The structure pointer points to the structure array
Code analysis, understand the structure pointer to the structure array
```
Output structure array with pointer variable, please analyze the code.
#include
struct stu{
int num;
char name[20];
char sex;
double score;
}s[5]={ {101,"XiaoDi_ Ma" , 'M', 45},
{102,"JuHao_ Zhu" , 'M',62.5},
{103,"XinHao_ Li" , 'F',92.5},
{104,"HongPeng_ Yang", 'F', 87},
{105,"YuHang_ Gao" , 'M', 58}
};
int main(){
struct stu *ps;
for(ps=s; psprintf("%d %-20s %c %lf\n",ps->num,ps->name,ps->sex,ps->score);
return 0;
}
```
###Input example:
```in
```
###Output example:
```out
101 XiaoDi_ Ma M 45.000000
102 JuHao_ Zhu M 62.500000
103 XinHao_ Li F 92.500000
104 HongPeng_ Yang F 87.000000
105 YuHang_ Gao M 58.000000
```
answer:If there is no answer, please comment
```
Output structure array with pointer variable, please analyze the code.
#include
struct stu{
int num;
char name[20];
char sex;
double score;
}s[5]={ {101,"XiaoDi_ Ma" , 'M', 45},
{102,"JuHao_ Zhu" , 'M',62.5},
{103,"XinHao_ Li" , 'F',92.5},
{104,"HongPeng_ Yang", 'F', 87},
{105,"YuHang_ Gao" , 'M', 58}
};
int main(){
struct stu *ps;
for(ps=s; ps
return 0;
}
```
###Input example:
```in
```
###Output example:
```out
101 XiaoDi_ Ma M 45.000000
102 JuHao_ Zhu M 62.500000
103 XinHao_ Li F 92.500000
104 HongPeng_ Yang F 87.000000
105 YuHang_ Gao M 58.000000
```
answer:If there is no answer, please comment