- 5
- 0
- 约3.36千字
- 约 11页
- 2026-04-28 发布于北京
- 举报
C++58期STL部分
Day18
一、文本查询扩展作业
shared_ptrstringsp2(newstring(hello));
shared_ptrvectorstringsp3(newvectorstring(hello));
10shared_ptrsetsize_tlines(newsetsize_t);
11
12
13
get_file函数的作用:
shared_ptrvectorstringfile存起来了;将单词与行号存放在mapstring,
Query类的实现
shared_ptrQuery_baseq;
Query::Query(conststd::strings)
10
11
12
Query_base类的实现
10
11
12
13
WordQuery类的实现
WordQuery(conststd::strings)
10
查询某个单词的时候,走的过程
1、通过cin将待查询的单词输入到sought中;
shared_ptrQue
原创力文档

文档评论(0)