停用词.cpp
来自「用来去除英文文档中的停用词」· C++ 代码 · 共 27 行
CPP
27 行
#include <iostream>
#include <fstream>
#include <string>
int main()
{
{
ifstream stopWordFile("stop.txt");
if(!stopWordFile.is_open())
return false;
// assert(stopWordFile);
char stopword[10];
stopWordFile.getline(stopword, 10);
while(strlen(stopword) != 0)
{
stop.push_back(stopword);
stopWordFile.getline(stopword, 10);
}
return true;
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?