Redian新闻
>
还有一个TP的official case,$23有人要吗?
avatar
还有一个TP的official case,$23有人要吗?# PDA - 掌中宝
m*9
1
终于暖和了,后面的那块地想种菜,
在什么店里面买种子呢?
avatar
w*0
2
The author in Item 11, said something about copy and assignment constructor
In following code, last line ,the author said a.data is already deleted
but I wrote a program, and did test. find the value is still there. thanks.
String a("Hello"); // define and construct a
{ // open new scope
String b("World"); // define and construct b
...
b = a; // execute default op=,
avatar
q*3
3
在HP HOME买的,现$23转+your label,或者$27包邮usps first class,有兴趣的请站
内联系,谢谢
avatar
j*f
4
homedepot有美国蔬菜。 各种亚洲店有亚洲蔬菜。

终于暖和了,后面的那块地想种菜,
在什么店里面买种子呢?

【在 m****9 的大作中提到】
: 终于暖和了,后面的那块地想种菜,
: 在什么店里面买种子呢?

avatar
f*4
5
Effective C++ Item 11 没看到你这个例子
但是,new scope里面的string b在出scope之后delete了,而不是a
avatar
c*b
6
gardening版有很多人免费送种子.

【在 m****9 的大作中提到】
: 终于暖和了,后面的那块地想种菜,
: 在什么店里面买种子呢?

avatar
w*0
7
hi Brother,
Yes, It has.
Item 11: Declare a copy constructor and an assignment operator for classes
with dynamically allocated memory.
Just because b out of scope, b was deleted.
we have b = a;
so b.data point to a.data
b delete, b.data and a.data was deleted too.
so the author said a.data is already deleted
but I use cout, it can print out a.data. weird.

【在 f****4 的大作中提到】
: Effective C++ Item 11 没看到你这个例子
: 但是,new scope里面的string b在出scope之后delete了,而不是a

avatar
m*9
8
哦,亚洲店,要去看看,
以前没有注意
多谢

【在 j**f 的大作中提到】
: homedepot有美国蔬菜。 各种亚洲店有亚洲蔬菜。
:
: 终于暖和了,后面的那块地想种菜,
: 在什么店里面买种子呢?

avatar
z*e
9
兄台,贴代码。String的实现。
avatar
s*i
10
除了HD,我们这里有些超市比如Fred Meyer,Top Food,QFC,Safeway都见过
avatar
g*1
11
string 和 String差别很大。不要搞混了
avatar
m*9
12
今天居然在dollar tree看到种子,虽然种类不多
-原来很多店都有
avatar
l*0
13
我都在homedepot买。
黄瓜,辣椒,番茄,白菜,包菜,豆角,南瓜等等都有的。
相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。