string tempstr = "动词,名词,动词.介词,叹词,数词.";
int coutNum = 0;
coutNum = TongJi(tempstr,",");
...
..
.
coutNum = TongJi(tempstr,".");
...
..
.
#TongJi函数应该怎么写?
int coutNum = 0;
coutNum = TongJi(tempstr,",");
...
..
.
coutNum = TongJi(tempstr,".");
...
..
.
#TongJi函数应该怎么写?
其实就是统计","有多少个
统计"."有多少个,返回int值,就可以了
谢谢!!
while(ss++)
{
if(ss == '.') n++;
}