📄 date.h
字号:
#ifndef DATE_H
#define DATE_H
class Date
{
public:
Date(int d1, int m1, int y1);
Date(int d1, int m1);
Date(int d1);
Date();
int getDay();
int getMonth();
int getYear();
friend Date& operator++(Date&);
friend Date& operator--(Date&);
Date& operator++(int);
Date& operator--(int);
void add_year(int n);
void add_month(int n);
void add_day(int n);
bool operator==(Date&);
bool operator!=(Date&);
bool operator<=(Date&);
bool operator>=(Date&);
bool operator<(Date&);
bool operator>(Date&);
int judge(int m,int y);
private:
int day;
int month;
int year;
};
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -