您的位置:首页 > 其它

Struct is the same as int and float

2004-09-17 20:20 405 查看
int:
int Number=0;
Number=InputNumber();
=============================
struct Date
{
  int Day;
  int Month;
  int Year;
};
struct Person
{
 struct Date DOB;
 char Name[16];
};
struct Date InputDOB()
{
  struct Date DOB;
  DOB.Day=1;
  DOB.Month=2;
  DOB.Year=3;
  return(DOB);
}
main()
{
  struct Person person;
  person.DOB=InputDOB();
}
 
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  struct date float
相关文章推荐