#include
typedef struct persion {
const char *name;
int age;
} persion[1], persion_t;
int main(void)
{
struct persion a;
struct persion *p = NULL;
struct persion *q = NULL;
a = (persion_t){"persion1", 25};
p = (persion){{"persion2", 27}};
q = (struct persion[]){{"persion3", 22}};
printf("%s %d\n", a.name, a.age);
printf("%s %d\n", p->name, p->age);
printf("%s %d\n", q->name, q->age);
return 0;
}
阅读(2254) | 评论(0) | 转发(0) |