avatar
Costco的玫瑰好不好?# gardening - 拈花惹草
i*0
1
大家来讨论一下c++吧
Please answer the following c++ questions. Do not simply answer yes/no.
Always explain your assumptions and reasoning.
1. memset is sometimes used to initialize data in a constructor like the
example below. What is the benefit of initializing this way? Does it work
in this example? Does it work in general ? Is it a good idea in general?
class A {
public:
A();
private:
int a;
float f;
char str[35];
long *lp;
};
A::A()
{
memset(this, 0, sizeof(*this));
}
2. Your task is to implement the Reduce function using templates. The
Reduce fn applies a function of two arguments cumulatively to the items of
an STL container, from begin() to end(), so as to reduce the sequence to a
single value. For example, Reduce(, std::plus>()) should calculate ((((1+2)+3)+4)+5).
class NotEnoughElements {};
template
typename Container::value_type
Reduce(const Container& c, Function fn) throw (NotEnoughElements)
{
FILL OUT
}
3. Write a C++ program that would find and print the first longest
ascending or descending contiguous subsequence for a vector of integers. For
example, given a vector with
4, 2, 1, 2, 3, 4, 3, 5, 1, 2, 4, 6, 5
the program would find the underlined subsequence and print it.
4. You have a class that many libraries depend on. Now you need to modify
the class for one application. Which of the following changes require
recompiling all libraries before it is safe to build the application?
a. add a constructor
b. add a data member
c. change destructor into virtual
d. add an argument with default value to an existing member function
avatar
A*r
2
我进了10棵costco的玫瑰。看起来都很健壮。但是好像很少听到版上讨论他家玫瑰。
我住8b.
avatar
c*p
3
哪里买的不重要,要看是什么品种,GRADE 是多少。
avatar
A*r
4
非常粗壮,象grade A, hybrid tea.
avatar
c*p
5
grade 1?
裸根是越粗壮越好,不用担心,应该是挺好的
另外,HYBRID TEA是玫瑰的一个类别,不是品种,在包装袋上应该有玫瑰品种的名字

【在 A********r 的大作中提到】
: 非常粗壮,象grade A, hybrid tea.
avatar
g*e
6
在我家这边的Costco没看到过啥好品种。

【在 c***p 的大作中提到】
: grade 1?
: 裸根是越粗壮越好,不用担心,应该是挺好的
: 另外,HYBRID TEA是玫瑰的一个类别,不是品种,在包装袋上应该有玫瑰品种的名字

avatar
c*p
7
记得我们这边是两颗一盒,或者是四棵一盒,里面好品种和一般品种混合
今年一直没买到小苍兰

【在 g***e 的大作中提到】
: 在我家这边的Costco没看到过啥好品种。
avatar
h*e
8
一般店里卖的不是hybrid tea就是 floribunda

【在 c***p 的大作中提到】
: grade 1?
: 裸根是越粗壮越好,不用担心,应该是挺好的
: 另外,HYBRID TEA是玫瑰的一个类别,不是品种,在包装袋上应该有玫瑰品种的名字

avatar
A*r
9
谢谢大家的回复。让我去看看具体品种,然后再报上来。
avatar
i*o
10
杯子,我在我这里的HD看到有

【在 c***p 的大作中提到】
: 记得我们这边是两颗一盒,或者是四棵一盒,里面好品种和一般品种混合
: 今年一直没买到小苍兰

avatar
Q*B
11
品质很好。品种你自己选择。不太多。
我种的hybrid,当年就能到一人高。
avatar
A*r
12
真的啊?太好了。
看起来比其他地方卖的粗壮很多。

【在 Q*B 的大作中提到】
: 品质很好。品种你自己选择。不太多。
: 我种的hybrid,当年就能到一人高。

avatar
Q*B
13
好像挖个好坑最重要。呵呵。
我有一颗挖了个巨大的坑。。。用了4 cub的好土。
其他的坑大概2cub大,也长得好,不如4cub的好。

【在 A********r 的大作中提到】
: 真的啊?太好了。
: 看起来比其他地方卖的粗壮很多。

avatar
A*r
14
今天,就挖坑去。

【在 Q*B 的大作中提到】
: 好像挖个好坑最重要。呵呵。
: 我有一颗挖了个巨大的坑。。。用了4 cub的好土。
: 其他的坑大概2cub大,也长得好,不如4cub的好。

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。