24,854
社区成员
发帖
与我相关
我的任务
分享
#include <iostream>
#include <fstream>
#include "seg.h"
using namespace std;
int main(int argc, char **argv)
{
if(argc < 3)
{
std::cout<<"using:segt.exe testFile resultFile"<<std::endl;
return 0;
}
std::cout<<"Copyright (C) 2011 - 2012."<<std::endl;
std::cout<<"Version: 0.6, Last update: 2012-07-01."<<std::endl;
std::string path = "input.txt";
std::string out = "output.txt";
path = argv[1];
out = argv[2];
GeWoSeg *seg = new GeWoSeg();
if(!seg->Tibetan(path,out))
std::cout<<"Seg Error!"<<std::endl;
delete seg;
return 0;
}