主页
C 语言
C 变量作用域
demo_scope_global
运行 ❯
×
更改方向
保存代码
更改主题
#include
// Global variable x int x = 5; void myFunction() { // We can use x here printf("%d\n", x); } int main() { myFunction(); // We can also use x here printf("%d\n", x); return 0; }
5
5