就是题里给“xx为指针类型”,就是char*加名字,有*说明是指针,头文件要加上“#include ”。
构造函数里面写套话——
int len=strlen(xxx);
xx=new char[len+1];
strcpy(xxx, xx);
PS:xxx是public里的,xx是private里的。
通常会配套析构函数,也是套话,以person为例——
Person::~Person()
{
delete []xxx;
}
构造函数里面写套话——
int len=strlen(xxx);
xx=new char[len+1];
strcpy(xxx, xx);
PS:xxx是public里的,xx是private里的。
通常会配套析构函数,也是套话,以person为例——
Person::~Person()
{
delete []xxx;
}
人和人如果不在一个层次上,那么无论你做什么,对方都觉得不对,所谓层次,不是社会地位,而是人品和认知事物的清晰程度。
If people and people are not on the same level, then no matter what you do, the other party will feel wrong, the so-called level, not social status, but character and the clarity of cognition of things.
If people and people are not on the same level, then no matter what you do, the other party will feel wrong, the so-called level, not social status, but character and the clarity of cognition of things.
#狂犬病治疗中心[超话]#engfa和tina tom一起去了新加坡,这是char的错,engfa和她聚会上的所有女人都亲吻拥抱,这是char的错,char应该为一切负责,char甚至不需要评审!直接被判有罪[666][666] engfa solo fc真牛[赞] 扭曲事实 招摇生事 一级棒 那些配合支持她的蠢货fans club
#engfawaraha##englot##charlotteaustin#
#engfawaraha##englot##charlotteaustin#
✋热门推荐