1.总体分析
采用的代码较为简单,基本没有任何语法。首先定义一个文件,接着直接利用cout将从wakeup课程表导出的.ics文件信息输出到另一个定义的.ical文件,由于从wakeup课程表导出的.ics文件信息没有周数信息,所以在最后用类似与该格式的方式一个一个输出周数信息。然后在代码的最后后关闭文件、编译、运行即产生所需要的文件。
2.详细设计
在程序的开头引入头文件iostream来实现通用输入输出流和其他输入输出流的基类的功能,又因为需要对文件进行操作,所以还需要fstream来实现输入输出文件流类的功能。接着使用“using namespace std;”来告诉编译器使用标准命名空间名字std。这样,编译器如果遇到一个非用户或C++定义的标识符,它会自动到使用的命名空间去查找。然后开始写主函数:利用ofstream cout(“myical.ical”);这段语句来在当前目录下创建一个名为myical的.ical类型的文件,默认文件的打开类型为写入,并清除该文件原有的全部数据(如果存在的话)。
接着利用cout依次逐个输出从wakeup课程表导出来的.ics文件的内容,并在后面加换行符\n,这样是为了分段,如果不加入则无法导入至谷歌日历(具体原因到现在也不清楚,反正不加入则无法导入谷歌日历)。
下面简要的解释上图从wakeup课程表导出的部分.ical文件各条语句所代表的含义(由于导出每个课程的信息各条语句意思基本一样,所以只解释其中一条;这部分并不是全部由wakeup课程表导出来的全部内容,在编写程序的同时还做了一些修改,删掉了一些不必要的,使代码尽量看起来简洁一些,例如UID:20190506T151815Z-WakeUpSchedule@fe80::10a9:49ff:fe73:5b3e%dummy0、PRODID:-//WakeUpSchedule //iCal4j 2.0//EN、VERSION:2.0以及CALSCALE:GREGORIAN):其中cout<< “BEGIN:VCALENDAR”;表示整个课程项目的开始,缺少必然无法导入;紧接着cout<<“BEGIN:VEVENT”;表示其中一个课程项目的开始,然后cout<< “DTSTART:20190304T080000\n”;和cout<< “DTEND:20190304T093500\n”;分别表示本学期该课程第一节课开始的时间为2019年3月4号早上8点整和结束的时间为2019年3月4号早上9点35分;而cout<<“SUMMARY:大学英语2(ABC)*\n”;很明显是表示课程名称;接着cout<<“LOCATION:校本部 北综楼211 蔡蕾\n”;以及 cout<< “DESCRIPTION:第1 - 2节\n校本部 北综楼211\n蔡蕾\n”;表示上课时间“第1-2节”、上课地点“校本部 北综楼211”以及上课老师“蔡蕾”;紧接着是“FREQ=WEEKLY;UNTIL=20190604T000000”表示以一周七天为单位进行循环2019年6月4号;最后是cout<<“END:VEVENT\n”;表示一个课程项目的结束。
按照如上的方法依次输出各个课程的信息,当然了,在某些细节方面还是要稍微修改一下。例如五一放假前后的下午晚上上课的时间有所变化,所以需要在此基础上对上课时间进行稍加改动。以离散数学为例,需要将3月18号开始至6月18号结束的课程分割为3月18至4月30和5月6号至6月18号两部分,并分别对其上课时间部分的代码进行修改即可,如右图所示。
最后还要需要输出各个日期所对应的周数,只要把每个周当成一个课程来进行输出即可,但是同样的也要删掉一些不必要的,例如上面所列出来各个课程对应的上课地点、老师以及具体的时间即可,按照此方法输出十八个“课程”(因为一共有十八周),如图所示。接着利用cout<<“END:VCALENDAR\n”<<endl;表示整个学期课程的结束,并将其显示出来。接着所有信息输出完到文件后利用cout.close();将文件关闭,最后利用return 0;返回0,至此,整个程序结束结束,然后编译、运行再将产生的文件直接导入谷歌日历即可。
3.源码
#include<iostream>
#include<fstream>
using namespace std;
int main()
{
ofstream cout("myical.ical");
cout<<"BEGIN:VCALENDAR\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190304T080000\n";
cout<<"DTEND:20190304T093500\n";
cout<<"SUMMARY:大学英语2(ABC) *\n";
cout<<"LOCATION:校本部 北综楼211 蔡蕾\n";
cout<<"DESCRIPTION:第1 - 2节\n校本部 北综楼211\n蔡蕾\n";
cout<<"RDATE;VALUE=PERIOD:20190304T080000/20190304T093500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190604T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190415T100500\n";
cout<<"DTEND:20190415T114000\n";
cout<<"SUMMARY:数字逻辑*\n";
cout<<"LOCATION:校本部 北综楼107 墙威\n";
cout<<"DESCRIPTION:第3 - 4节\n校本部 北综楼107\n墙威\n";
cout<<"RDATE;VALUE=PERIOD:20190415T100500/20190415T114000\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190625T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190318T140000\n";
cout<<"DTEND:20190318T153500\n";
cout<<"SUMMARY:离散数学B*\n";
cout<<"LOCATION:校本部 北综楼111 吴亦奇\n";
cout<<"DESCRIPTION:第5 - 6节\n校本部 北综楼111\n吴亦奇\n";
cout<<"RDATE;VALUE=PERIOD:20190318T140000/20190318T153500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190430T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190506T143000\n";
cout<<"DTEND:20190506T160500\n";
cout<<"SUMMARY:离散数学B*\n";
cout<<"LOCATION:校本部 北综楼111 吴亦奇\n";
cout<<"DESCRIPTION:第5 - 6节\n校本部 北综楼111\n吴亦奇\n";
cout<<"RDATE;VALUE=PERIOD:20190506T143000/20190506T160500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190618T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190429T160500\n";
cout<<"DTEND:20190429T174000\n";
cout<<"SUMMARY:地球科学概论*\n";
cout<<"LOCATION:校本部 北综楼102 余文超\n";
cout<<"DESCRIPTION:第7 - 8节\n校本部 北综楼102\n余文超\n";
cout<<"RDATE;VALUE=PERIOD:20190429T160500/20190429T174000\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190430T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190506T163500\n";
cout<<"DTEND:20190506T181000\n";
cout<<"SUMMARY:地球科学概论*\n";
cout<<"LOCATION:校本部 北综楼102 余文超\n";
cout<<"DESCRIPTION:第7 - 8节\n校本部 北综楼102\n余文超\n";
cout<<"RDATE;VALUE=PERIOD:20190506T163500/20190506T181000\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190625T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190304T190000\n";
cout<<"DTEND:20190304T203500\n";
cout<<"SUMMARY:中国城市转型*\n";
cout<<"LOCATION:校本部 北综楼309 宋小青\n";
cout<<"DESCRIPTION:第9 - 10节\n校本部 北综楼309\n宋小青\n";
cout<<"RDATE;VALUE=PERIOD:20190304T190000/20190304T203500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190429T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190506T193000\n";
cout<<"DTEND:20190506T211000\n";
cout<<"SUMMARY:中国城市转型*\n";
cout<<"LOCATION:校本部 北综楼309 宋小青\n";
cout<<"DESCRIPTION:第9 - 10节\n校本部 北综楼309\n宋小青\n";
cout<<"RDATE;VALUE=PERIOD:20190506T193000/20190506T211000\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190521T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190226T080000\n";
cout<<"DTEND:20190226T093500\n";
cout<<"SUMMARY:高等数学A2*\n";
cout<<"LOCATION:校本部 北综楼405 刘汉兵\n";
cout<<"DESCRIPTION:第1 - 2节\n校本部 北综楼405\n刘汉兵\n";
cout<<"RDATE;VALUE=PERIOD:20190226T080000/20190226T093500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190626T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190226T100500\n";
cout<<"DTEND:20190226T114000\n";
cout<<"SUMMARY:游泳\n";
cout<<"LOCATION:校本部 游泳馆 熊昌进\n";
cout<<"DESCRIPTION:第3 - 4节\n校本部 游泳馆\n熊昌进\n";
cout<<"RDATE;VALUE=PERIOD:20190226T100500/20190226T114000\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190626T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190226T140000\n";
cout<<"DTEND:20190226T153500\n";
cout<<"SUMMARY:电工与电子技术C*\n";
cout<<"LOCATION:校本部 北综楼407 张惠捷\n";
cout<<"DESCRIPTION:第5 - 6节\n校本部 北综楼407\n张惠捷\n";
cout<<"RDATE;VALUE=PERIOD:20190226T140000/20190226T153500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190501T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190416T190000\n";
cout<<"DTEND:20190416T203500\n";
cout<<"SUMMARY:高级软件编程技术*\n";
cout<<"LOCATION:校本部 北综楼210 熊慕舟\n";
cout<<"DESCRIPTION:第9 - 10节\n校本部 北综楼210\n熊慕舟\n";
cout<<"RDATE;VALUE=PERIOD:20190416T190000/20190416T203500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190501T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190227T080000\n";
cout<<"DTEND:20190227T093500\n";
cout<<"SUMMARY:高等数学A2*\n";
cout<<"LOCATION:校本部 北综楼405 刘汉兵\n";
cout<<"DESCRIPTION:第1 - 2节\n校本部 北综楼405\n刘汉兵\n";
cout<<"RDATE;VALUE=PERIOD:20190227T080000/20190227T093500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190425T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190508T080000\n";
cout<<"DTEND:20190508T093500\n";
cout<<"SUMMARY:高等数学A2*\n";
cout<<"LOCATION:校本部 北综楼405 刘汉兵\n";
cout<<"DESCRIPTION:第1 - 2节\n校本部 北综楼405\n刘汉兵\n";
cout<<"RDATE;VALUE=PERIOD:20190508T080000/20190508T093500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190627T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190417T100500\n";
cout<<"DTEND:20190417T114000\n";
cout<<"SUMMARY:数字逻辑*\n";
cout<<"LOCATION:校本部 北综楼404 墙威\n";
cout<<"DESCRIPTION:第3 - 4节\n校本部 北综楼404\n墙威\n";
cout<<"RDATE;VALUE=PERIOD:20190417T100500/20190417T114000\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190425T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190508T100500\n";
cout<<"DTEND:20190508T11400\n";
cout<<"SUMMARY:数字逻辑*\n";
cout<<"LOCATION:校本部 北综楼404 墙威\n";
cout<<"DESCRIPTION:第3 - 4节\n校本部 北综楼404\n墙威\n";
cout<<"RDATE;VALUE=PERIOD:20190508T100500/20190508T114000\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190620T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190313T140000\n";
cout<<"DTEND:20190313T153500\n";
cout<<"SUMMARY:离散数学B*\n";
cout<<"LOCATION:校本部 北综楼111 吴亦奇\n";
cout<<"DESCRIPTION:第5 - 6节\n校本部 北综楼111\n吴亦奇\n";
cout<<"RDATE;VALUE=PERIOD:20190313T140000/20190313T153500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190425T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190508T143000\n";
cout<<"DTEND:20190508T160500\n";
cout<<"SUMMARY:离散数学B*\n";
cout<<"LOCATION:校本部 北综楼111 吴亦奇\n";
cout<<"DESCRIPTION:第5 - 6节\n校本部 北综楼111\n吴亦奇\n";
cout<<"RDATE;VALUE=PERIOD:20190508T143000/20190508T160500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190620T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190228T080000\n";
cout<<"DTEND:20190228T093500\n";
cout<<"SUMMARY:电工与电子技术C*\n";
cout<<"LOCATION:校本部 北综楼405 张惠捷\n";
cout<<"DESCRIPTION:第1 - 2节\n校本部 北综楼405\n张惠捷\n";
cout<<"RDATE;VALUE=PERIOD:20190228T080000/20190228T093500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190503T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190228T100500\n";
cout<<"DTEND:20190228T114000\n";
cout<<"SUMMARY:大学英语2(ABC)*\n";
cout<<"LOCATION:校本部 北综楼211 蔡蕾\n";
cout<<"DESCRIPTION:第3 - 4节\n校本部 北综楼211\n蔡蕾\n";
cout<<"RDATE;VALUE=PERIOD:20190228T100500/20190228T114000\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190531T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190606T100500\n";
cout<<"DTEND:20190606T114000\n";
cout<<"SUMMARY:高等数学A2*\n";
cout<<"LOCATION:校本部 北综楼405 刘汉兵\n";
cout<<"DESCRIPTION:第3 - 4节\n校本部 北综楼405\n刘汉兵\n";
cout<<"RDATE;VALUE=PERIOD:20190606T100500/20190606T114000\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190607T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190418T190000\n";
cout<<"DTEND:20190418T20350000\n";
cout<<"SUMMARY:高级软件编程技术*\n";
cout<<"LOCATION:校本部 北综楼210 熊慕舟\n";
cout<<"DESCRIPTION:第9 - 10节\n校本部 北综楼210\n熊慕舟\n";
cout<<"RDATE;VALUE=PERIOD:20190418T190000/20190418T203500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190426T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190301T080000\n";
cout<<"DTEND:20190301T093500\n";
cout<<"SUMMARY:高等数学A2*\n";
cout<<"LOCATION:校本部 北综楼405 刘汉兵\n";
cout<<"DESCRIPTION:第1 - 2节\n校本部 北综楼405\n刘汉兵\n";
cout<<"RDATE;VALUE=PERIOD:20190301T080000/20190301T093500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190330T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190412T080000\n";
cout<<"DTEND:20190412T093500\n";
cout<<"SUMMARY:高等数学A2*\n";
cout<<"LOCATION:校本部 北综楼405 刘汉兵\n";
cout<<"DESCRIPTION:第1 - 2节\n校本部 北综楼405\n刘汉兵\n";
cout<<"RDATE;VALUE=PERIOD:20190412T080000/20190412T093500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190601T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190614T080000\n";
cout<<"DTEND:20190614T09350000\n";
cout<<"SUMMARY:高等数学A2*\n";
cout<<"LOCATION:校本部 北综楼405 刘汉兵\n";
cout<<"DESCRIPTION:第1 - 2节\n校本部 北综楼405\n刘汉兵\n";
cout<<"RDATE;VALUE=PERIOD:20190614T080000/20190614T093500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190629T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190322T140000\n";
cout<<"DTEND:20190322T153500\n";
cout<<"SUMMARY:生涯规划与就业指导\n";
cout<<"LOCATION:校本部 教三楼501 李春卉\n";
cout<<"DESCRIPTION:第5 - 6节\n校本部 教三楼501\n李春卉\n";
cout<<"RDATE;VALUE=PERIOD:20190322T140000/20190322T153500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190420T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190503T163500\n";
cout<<"DTEND:20190503T181000\n";
cout<<"SUMMARY:地球科学概论*\n";
cout<<"LOCATION:校本部 北综楼103 喻建新,余文超\n";
cout<<"DESCRIPTION:第7 - 8节\n校本部 北综楼103\n喻建新,余文超\n";
cout<<"RDATE;VALUE=PERIOD:20190503T163500/20190503T181000\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190601T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190614T163500\n";
cout<<"DTEND:20190614T181000\n";
cout<<"SUMMARY:地球科学概论*\n";
cout<<"LOCATION:校本部 北综楼103 喻建新,余文超\n";
cout<<"DESCRIPTION:第7 - 8节\n校本部 北综楼103\n喻建新,余文超\n";
cout<<"RDATE;VALUE=PERIOD:20190614T163500/20190614T181000\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190622T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:201900502T193000\n";
cout<<"DTEND:20190502T21050000\n";
cout<<"SUMMARY:高级软件编程技术*\n";
cout<<"LOCATION:校本部 北综楼210 熊慕舟\n";
cout<<"DESCRIPTION:第9 - 10节\n校本部 北综楼210\n熊慕舟\n";
cout<<"RDATE;VALUE=PERIOD:20190418T193000/20190418T210500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=201900621T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190507T193000\n";
cout<<"DTEND:20190507T21050000\n";
cout<<"SUMMARY:高级软件编程技术*\n";
cout<<"LOCATION:校本部 北综楼210 熊慕舟\n";
cout<<"DESCRIPTION:第9 - 10节\n校本部 北综楼210\n熊慕舟\n";
cout<<"RDATE;VALUE=PERIOD:20190418T193000/20190418T210500\n";
cout<<"RRULE:FREQ=WEEKLY;UNTIL=20190619T000000;INTERVAL=1\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190225T000000\n";
cout<<"DTEND:20190303T000000\n";
cout<<"SUMMARY:第一周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190304T000000\n";
cout<<"DTEND:20190310T000000\n";
cout<<"SUMMARY:第二周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190311T000000\n";
cout<<"DTEND:20190317T000000\n";
cout<<"SUMMARY:第三周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190318T000000\n";
cout<<"DTEND:20190324T000000\n";
cout<<"SUMMARY:第四周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190325T000000\n";
cout<<"DTEND:20190331T000000\n";
cout<<"SUMMARY:第五周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190401T000000\n";
cout<<"DTEND:20190407T000000\n";
cout<<"SUMMARY:第六周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190408T000000\n";
cout<<"DTEND:20190414T000000\n";
cout<<"SUMMARY:第七周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190415T000000\n";
cout<<"DTEND:20190421T000000\n";
cout<<"SUMMARY:第八周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190422T000000\n";
cout<<"DTEND:20190428T000000\n";
cout<<"SUMMARY:第九周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190429T000000\n";
cout<<"DTEND:20190505T000000\n";
cout<<"SUMMARY:第十周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190506T000000\n";
cout<<"DTEND:20190512T000000\n";
cout<<"SUMMARY:第十一周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190513T000000\n";
cout<<"DTEND:20190519T000000\n";
cout<<"SUMMARY:第十二周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190520T000000\n";
cout<<"DTEND:20190526T000000\n";
cout<<"SUMMARY:第十三周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190527T000000\n";
cout<<"DTEND:20190602T000000\n";
cout<<"SUMMARY:第十四周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190603T000000\n";
cout<<"DTEND:20190609T000000\n";
cout<<"SUMMARY:第十五周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190610T000000\n";
cout<<"DTEND:20190616T000000\n";
cout<<"SUMMARY:第十六周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190617T000000\n";
cout<<"DTEND:20190623T000000\n";
cout<<"SUMMARY:第十七周*\n";
cout<<"END:VEVENT\n";
cout<<"BEGIN:VEVENT\n";
cout<<"DTSTART:20190624T000000\n";
cout<<"DTEND:20190630T000000\n";
cout<<"SUMMARY:第十八周*\n";
cout<<"END:VEVENT\n";
cout<<"END:VCALENDAR\n"<<endl;
cout.close();
return 0;
}