TA的每日心情 | 奋斗 2022-12-13 21:26 |
---|
签到天数: 371 天 [LV.9]以坛为家II
|
本帖最后由 Sian 于 2014-2-20 21:02 编辑
请推断出以下代码的输出:
- #include <stdio.h>
- int main() {
-
- int score = 100;
-
- {
- int score = 200;
-
- {
- score = 300;
-
- printf("score = %d\n",score);
- }
-
- printf("score = %d\n", score);
- }
-
- printf("score = %d\n", score);
-
- }
复制代码 理解C语言变量的作用域
|
|