3.24
来源:互联网 发布:dia frampton知乎 编辑:程序博客网 时间:2024/06/05 22:55
#include<iostream>
using namespace std;
class Date
{
public:
Date(int year,int month,int day)
{
y=year;
m=month;
d=day;
}
void getyear();
void getmonth();
void getday();
void display();
private:
int y,m,d;
};
void Date::display()
{
cout<<y<<"年"<<m<<"月"<<d<<"日"<<endl;
}
int main()
{
Date z(2014,4,1);
cout<<"z的相关信息是:"<<endl;
z.display();
return 0;
}
using namespace std;
class Date
{
public:
Date(int year,int month,int day)
{
y=year;
m=month;
d=day;
}
void getyear();
void getmonth();
void getday();
void display();
private:
int y,m,d;
};
void Date::display()
{
cout<<y<<"年"<<m<<"月"<<d<<"日"<<endl;
}
int main()
{
Date z(2014,4,1);
cout<<"z的相关信息是:"<<endl;
z.display();
return 0;
}
0 0
- 3.24
- 3.24
- 3.24
- 3.24
- 3.24
- 3.24
- 3.24
- 【3.24】
- 3.24
- 3.24
- 3.24
- 3.24
- 3.24
- 3.24
- 3.24
- 3.24
- 3.24
- 3.24
- Iptables 规则 一些简单实例和详细介绍
- Bias 和 Variance的理解
- 作业3.22
- 文章标题
- 脚本之家在线工具
- 3.24
- K好数
- T-Sql 递归查询(给定节点查所有父节点、所有子节点的方法)
- Protocol Buffers Developer Guide-Tutorials -C++ Tutorial
- 2015年大一下第3周项目4-指向学生类的指针
- SDUT 2164-Binomial Coeffcients(组合数求模)
- makefile入门举例(简单写)
- 阿里面试经历及总结(数据研发、Java研发方向)
- 理解RESTful架构