函数返回值
#include<stdio.h>struct date{
int year;
int month;
int day;
} today={0,0,0};
struct date* get(struct date*);
int main()
{
struct date *p=&today;
get(&today);
printf("%d-%d-%d",p->year,p->month,p->day);
return 0;
}
struct date* get(struct date*p)
{
printf("请输入:");
scanf("%d %d %d",&p->year,&p->month,&p->day);
return p;
}
问一下大佬们在get函数中我要输入两个p该怎样返回