close
#include <iostream>
#include <string>
#include <vector>
#include <boost/algorithm/string/classification.hpp>
#include <boost/algorithm/string/split.hpp>
 
using namespace std;
 
int main()
{
  string s = "sss/ddd,ggg";
  vector<string> vStr;
  boost::split( vStr, s, boost::is_any_of( ",/" ), boost::token_compress_on );
  for( vector<string>::iterator it = vStr.begin(); it != vStr.end(); ++ it )
    cout << *it << endl;
  return 0;
}
arrow
arrow
    全站熱搜
    創作者介紹
    創作者 Allen 的頭像
    Allen

    Allen的部落格

    Allen 發表在 痞客邦 留言(0) 人氣()