官术网_书友最值得收藏!

  • The Modern C++ Challenge
  • Marius Bancila
  • 61字
  • 2021-06-25 22:01:29

27. Splitting a string into tokens with a list of possible delimiters

Write a function that, given a string and a list of possible delimiter characters, splits the string into tokens separated by any of the delimiters and returns them in an std::vector.

Example: input: "this,is.a sample!!" with delimiters ",.! ", output: {"this", "is", "a", "sample"}.

主站蜘蛛池模板: 双柏县| 合川市| 高淳县| 金昌市| 通河县| 海南省| 思南县| 克什克腾旗| 酒泉市| 济源市| 清镇市| 高碑店市| 淮南市| 鹤峰县| 蓬溪县| 开远市| 伊吾县| 札达县| 佛坪县| 弥勒县| 呈贡县| 张北县| 青龙| 黄龙县| 华坪县| 新安县| 土默特右旗| 绥化市| 新疆| 徐闻县| 白玉县| 江油市| 靖江市| 施甸县| 扎鲁特旗| 堆龙德庆县| 容城县| 兖州市| 临夏县| 苍南县| 松潘县|