remove char from stringstream and append some data

后端 未结 9 1495
情深已故
情深已故 2020-12-31 01:42

In my code there is a loop that adds sth like that \"number,\" to stringstream. When it ends, I need to extract \',\' add \'}\' and add \'{\' if the loop is to repeated.

9条回答
  •  無奈伤痛
    2020-12-31 02:13

    Why not just check the counter? And not insert the ','

    douCoh << '{';
    for(unsigned int i=0;i

提交回复
热议问题