Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create Date.h #45

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions 201816040230/Ex03_15/Date.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@

using namespace std;
class Date
{
public:
Date(int,int,int);//定义构造函数
void setMonth(int);//月的set函数
int getMonth();//月的get函数
void setDay(int);//日的set函数
int getDay();//日的get函数
void setYear(int);//年的set函数
int getYear();//年的get函数
void displayDate();//输出数据
private:
int month;
int day;
int year;
};