单选题
1分
有如下语句序列: int count=10,&ref=count; &nb...
有如下语句序列:
int count=10,&ref=count;
count+=100;
cout<<ref;
执行后的输出结果是()。
int count=10,&ref=count;
count+=100;
cout<<ref;
执行后的输出结果是()。
参考答案: C
参考解析: 变量ref为引用,指向count,现在执行count+=100语句,得到count=110;因此,ref的值为110.故答案C选项。