![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
笔记
g.aojingwen
这个作者很懒,什么都没留下…
展开
-
2021-04-24
如何输出一个数个各个位 逆序输出:例123 求个位 -> %10 丢个位 -> /=10 3 12 2 1 ...原创 2021-04-24 18:00:40 · 59 阅读 · 0 评论 -
2020-06-03
break只能在switch/循环语句中使用 continue:结束本次循环 在while中跳转到判断 在for中 跳转到语句3原创 2020-06-03 17:32:01 · 97 阅读 · 0 评论 -
2020-06-03
逗号表达式 scanf(“%d”,&n); while(n!=0) { sum+=n; scanf(“%d”,&n); } 可以改写为 while(scanf(“%d”,&n),n!=0) { sum+=n; }原创 2020-06-03 17:17:45 · 69 阅读 · 0 评论 -
2020-06-03
循环语句 for( ; ; ) 条件可省略 while(1) 每次循环都需要判断 while( x ) x非0⃣️即为真 x不可以省略 如果省略程序报错原创 2020-06-03 17:09:39 · 90 阅读 · 0 评论 -
2020-06-03
函数 1.函数的声明 例 bool is_leapyear (int year); year 可省略 2.函数的定义 Bool is_leapyear (int year) { } 3.函数的调用 is_leapyear(year)原创 2020-06-03 17:03:32 · 93 阅读 · 0 评论 -
const
const 一定要要初始化 const int a = 1; int const a = 1; const int a[] = {};原创 2020-05-31 18:40:06 · 107 阅读 · 0 评论