#pragma region secref.8.3
//程序清单8.3
//secref.cpp – defining and using a reference
#if 0
#include
int main()
{
using namespace std;
int rats = 101;
int& rodents = rats;
cout << "rats = " << rats;
cout << ",rodents = " << rodents << endl;
cout << "rats address = " << &rats;
cout << ",rodents address = " << &rodents << endl;
int bunnies = 50;
rodents = bunnies;//can we change the reference?
cout << "bunnies = " << bunnies;
cout << ",rats = " << rats;
cout << ",rodents = " << rodents << endl;
cout << "bunnies address = " << &bunnies;
cout << ",rodents address = " << &rodents << endl;
return 0;
}
#endif
#pragma endregion