typedef struct student
{
u8 num;
u8 *p;
}STU;
STU st1;
u8 bufdata[20];
void init_stu(STU *st)
{
st->num = 10;
st->p[0] = 12;
st->p[1] = 13;
}
int main(void)
{
st1.p = bufdata;
init_stu(&st1);
printf("the age num = %d \r\n",st1.num);
printf("the age num1 = %d \r\n",st1.p[0]);
printf("the age num2 = %d \r\n",st1.p[1]);
printf("the age bufdata1 = %d \r\n",bufdata[0]);
printf("the age bufdata2 = %d \r\n",bufdata[1]);