📄 createreference.cpp
字号:
//Listing 11.1
// Creating and Using References
#include <iostream>
int main()
{
int intOne;
int &rSomeRef = intOne;
intOne = 5;
std::cout << "intOne: " << intOne << std::endl;
std::cout << "rSomeRef: " << rSomeRef << std::endl;
rSomeRef = 7;
std::cout << "intOne: " << intOne << std::endl;
std::cout << "rSomeRef: " << rSomeRef << std::endl;
return 0;
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -