摘要:
void swap(int &rx,int &ry) //这里到底是什么意思??
{
int temp;
cout"swap.before swap. rx: "rx" ry: "ryendl;
temp=rx;
rx=ry;
ry=temp; 阅读全文
摘要:
cout"&intone "&intoneendl;
cout"&rsomeref "&rsomerefendl; 阅读全文
摘要:
#include using namespace std; int main() { int intone; int &rsomeref=intone; intone=5; cout<<"intone "<<intone<<endl <<"&rsomeref "<<rsomeref<<endl; rsomeref=7; cout<<"intone "<... 阅读全文
摘要:
#include using namespace std; class Rectangle { public: Rectangle(); ~Rectangle(); void setlength(int length){itslength=length;} int getlength()const{return itslength;} void setwidth(int width){... 阅读全文