当前位置:网站首页>code snippet
code snippet
2022-07-21 11:18:00 【Early lunar month in Pingqiu】
Split... By format string
void split(const std::string &s, std::vector<std::string> &sv,
const char *delim = " ") {
sv.clear();
char *buffer = new char[s.size() + 1];
buffer[s.size()] = '\0';
std::copy(s.begin(), s.end(), buffer);
char *p = std::strtok(buffer, delim);
do {
sv.emplace_back(p);
} while ((p = std::strtok(NULL, delim)));
delete[] buffer;
return;
}
边栏推荐
- 关于 '不记得' 这个词
- “海信的 B 面”科技展开幕!海信 B2B 代表产品首次集体亮相!
- opencv图像数据增强
- 半导体新晋独角兽,TCL刚刚投了18亿
- 建议收藏 | 可实操,数据中台选型示例
- 2021/7/16 学习散射网络第一步-神经网络入门
- Hydrogen future, China hydrogen energy alliance held the launching ceremony of 2022 hydrogen energy specialty and new entrepreneurship competition
- Understand the secondary node of industrial Internet identity analysis
- TNN笔记
- 李宏毅老师2020年深度学习系列讲座笔记3
猜你喜欢
李宏毅老师2020年深度学习系列讲座笔记7
Hydrogen future, China hydrogen energy alliance held the launching ceremony of 2022 hydrogen energy specialty and new entrepreneurship competition
会员数继续下滑,Netflix能靠广告突围吗?
Some things about pointer array and array pointer
Influxdb query timestamp problem
IP 第一次实验 HDCL封装 PPP,CHAP ,MGRE
ICASSP 2022 | 用于多模态情感识别的KS-Transformer
半导体新晋独角兽,TCL刚刚投了18亿
论文笔记:Accurate Causal Inference on Discrete Data
網絡安全學習(七)IIS
随机推荐
通过detectron2学习AI
find_ var.sh
Analysis of WPF multi finger application development
网络安全学习(九)综合实验&PKI
自动部署py脚本
Analysis of the overall architecture and accounting logic architecture of hyperledger fabric 1.0
氢创未来,中国氢能联盟举办2022氢能专精特新创业大赛启动仪式
kakfa常用命令
网络安全学习(四)用户与组管理,NTFS
激励函数的作用之sigmoid
网络安全学习(一)虚拟机
yolov5
高通连发三款处理器:骁龙730G有望成为次旗舰首选!
关于开放封闭原则
網絡安全學習(七)IIS
关于指针数组与数组指针的一些事
2021/7/24 SVM 2021/7/26 后门学习&对抗神经网络
如何有效规避代码被“投毒”?
李宏毅2020机器学习深度学习笔记1+2 &&深度学习基础与实践课程笔记2
Network Security Learning (IX) comprehensive experiment & PKI