⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 usedate.cpp

📁 C++&datastructure书籍源码,以前外教提供现在与大家共享
💻 CPP
字号:
#include <iostream>#include "date.h"using namespace std;// show Date member functionsint main(){    Date today;    Date birthDay(7,4,1776);	Date million(1000000L);    Date badDate(3,38,1999);    Date y2k(1,1,2000);    cout << "today   \t: "  << today    << endl;    cout << "US bday \t: "  << birthDay << endl;    cout << "million \t: "  << million  << endl;    cout << "bad date \t: " << badDate  << endl << endl;        cout << y2k << " is a " << y2k.DayName() << endl << endl;        Date one = million - 999999L;    Date birthDay2000(birthDay.Month(), birthDay.Day(), 2000);    today++;        cout << "day one \t: "   << one << " on a " << one.DayName() << endl;    cout << "bday2K  \t: "   << birthDay2000 << endl;    cout << "tomorrow \t: "  << today << endl;        return 0;}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -