惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Martin Fowler
Martin Fowler
Microsoft Security Blog
Microsoft Security Blog
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
Vercel News
Vercel News
Y
Y Combinator Blog
D
DataBreaches.Net
IT之家
IT之家
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
博客园_首页
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
H
Hackread – Cybersecurity News, Data Breaches, AI and More
WordPress大学
WordPress大学
H
Help Net Security
GbyAI
GbyAI
C
Check Point Blog
L
LangChain Blog
小众软件
小众软件
T
The Blog of Author Tim Ferriss
MyScale Blog
MyScale Blog
G
Google Developers Blog
月光博客
月光博客
V
V2EX
M
MIT News - Artificial intelligence
博客园 - 叶小钗

博客园 - pipicfan

unity性能优化之Drawcall优化 谈谈我是如何面试技术人员的 Shader中颜色的加法和乘法的区别 unity性能优化-实际开发中需要注意的点 cocos2dx 新手引导 c++面试题 c++实现委托 屁屁桌面管理 War3Tool dota改键v3.3版 魔兽全屏改键工具 很犀利的错误 关于vs2003环境支持win7 的 IP设置 自己的毕业设计windows管理软件 很容易犯的错误 敏感词过滤和谐社会1.0版 宿舍计费系统105加强版 自己实现string类 用C++ 设计一个不能被继承的类 (转)字符编码笔记:ASCII,Unicode和UTF-8
向字符数组中插入一个字符
pipicfan · 2018-11-06 · via 博客园 - pipicfan
    char comment[32] = "test#20170420|0420";
    char *pos = strchr(comment, '#');
    char front[32]={0};
    char back[32]={0};
    char newComment[32] = {0};
    memcpy(front, comment, pos-comment);
    strcpy_s(back, pos);
    sprintf_s(newComment, "%sC%s", front, back);
    std::cout<<newComment<<endl;

任何new内存都是消耗的,正确的做法是使用memcpy