填空题

下列程序由两个文件组成,其运行结果是()。
/* 文件 1 */
int x;
sub()
{x=4;   }
/* 文件 2 */
static int x=2;
main()
{sub();printf(“x=%d\n”,x);   }

答案: x=2
微信扫码免费搜题