会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
dxwxb
博客园
首页
新随笔
联系
订阅
管理
2024年3月12日
const的理解
摘要: Const 什么是CONST 被const修饰后的变量,只能保持一个值,无法再次赋值(一次指定用一辈子); int main(){ const int age=18; //age =20;//这句错误无法执行!!! return 0 ; } 如果修饰的是类、结构体、结构体或类的指针、其成员都不可以更
阅读全文
posted @ 2024-03-12 11:58 dxwxb
阅读(97)
评论(0)
推荐(0)
2024年3月11日
Inline内联函数简单理解
摘要: InLine_Function How to Write it? example-> inline void func(); inline int sum(int v1 , int v2 ); inline void func(){ std::cout<<"func()"<<std::endl; }
阅读全文
posted @ 2024-03-11 17:37 dxwxb
阅读(57)
评论(0)
推荐(0)
公告