avatar
K7+1855kit lens $899如何?# PhotoGear - 摄影器材
w*o
1
array里的元素是可以重复的对吧?
set里的元素是不能重复的对吧?
求intersection, union应该分别用什么数据结构和算法?
谢谢!
avatar
n*a
2
Amex Biz Gold有什么特有的周年优惠吗,像personal的$200 airline之类的。谢谢!
avatar
y*n
4
hash table.
Or you can sort it and use the same strategy as merge in merge sort.
if there is k array, use the same strategy in k way merge, use an heap to
hold head elements.
avatar
a*a
5
personal的有这个?

【在 n*******a 的大作中提到】
: Amex Biz Gold有什么特有的周年优惠吗,像personal的$200 airline之类的。谢谢!
avatar
w*o
7
能否具体的说说怎么用hashtable来解决这些问题?
xiexie!

【在 y*****n 的大作中提到】
: hash table.
: Or you can sort it and use the same strategy as merge in merge sort.
: if there is k array, use the same strategy in k way merge, use an heap to
: hold head elements.

avatar
d*j
8
没有。personal也没有200 airline. platinum的有,但200也不是让你买机票,虽然他
家系统买机票也认了。

【在 n*******a 的大作中提到】
: Amex Biz Gold有什么特有的周年优惠吗,像personal的$200 airline之类的。谢谢!
avatar
y*n
10
put all elements of one array into an hashtable, then scan another array to
check if current element is in hashtable, if yes then current element is
belong to intersection.
for union, just use hashset, put all elements in two arrays in hashset, then
the elements in hashset is what you want.
hashset will not permit repeated elements(at least in java= =)
avatar
n*a
11
想说的是personal的白金有 不好意思没说清楚

【在 a*******a 的大作中提到】
: personal的有这个?
avatar
T*t
12
你见过老娘的片片?

【在 y*********e 的大作中提到】
: 你不像。
avatar
w*o
13
yezhuen,
谢谢你的回答,
你这里做intersection的时候用到的hashtable里到底存的是什么?是数组里的数吗?
还只是存和相应数对应后(经过了hash fuction)的一个flag?
你做union的时候,用到的hashset里面存的是数组里的数,对吧?
谢谢!

to
then

【在 y*****n 的大作中提到】
: put all elements of one array into an hashtable, then scan another array to
: check if current element is in hashtable, if yes then current element is
: belong to intersection.
: for union, just use hashset, put all elements in two arrays in hashset, then
: the elements in hashset is what you want.
: hashset will not permit repeated elements(at least in java= =)

avatar
i*g
14
Amex gold的最好offer是75k吗?
avatar
c*q
15
老娘是喜欢纪念版的中华御宅摄影女~

【在 y*********e 的大作中提到】
: 你不像。
avatar
y*n
16
都存的数组里的数吧。hashfunction算出来的hashcode是当hashtable里的index用的吧。

【在 w****o 的大作中提到】
: yezhuen,
: 谢谢你的回答,
: 你这里做intersection的时候用到的hashtable里到底存的是什么?是数组里的数吗?
: 还只是存和相应数对应后(经过了hash fuction)的一个flag?
: 你做union的时候,用到的hashset里面存的是数组里的数,对吧?
: 谢谢!
:
: to
: then

avatar
g*a
17
open savings
avatar
T*t
18
奔....

【在 c******q 的大作中提到】
: 老娘是喜欢纪念版的中华御宅摄影女~
avatar
w*z
19
It doesn't matter what you put in this case. You can use HashSet, you don't
care about the value, you only care the existence of the key.
Java Hashset internally is backed by a hashmap, it stores the "this" as
value.
/**
* Adds the specified object to this HashSet.
*
* @param object
* the object to add
* @return true when this HashSet did not already contain the object,
false
* otherwise
*/
@Override
public boolean add(E object) {
return backingMap.put(object, this) == null;
}
For the hashvalue of the key, it's used to determine the bucket of the
hashtable. Java HashMap will do some processing on the hashvalue to avoid
conflicting.
static int hash(int h) {
// This function ensures that hashCodes that differ only by
// constant multiples at each bit position have a bounded
// number of collisions (approximately 8 at default load factor).
h ^= (h >>> 20) ^ (h >>> 12);
return h ^ (h >>> 7) ^ (h >>> 4);
}
You can look at Java source code for more details:
http://hg.openjdk.java.net/jdk6/jdk6/jdk/file/a42d6999734b/src/

吧。

【在 y*****n 的大作中提到】
: 都存的数组里的数吧。hashfunction算出来的hashcode是当hashtable里的index用的吧。
avatar
m*e
22
贱人卡你都忘了。
8折呀。

【在 p****n 的大作中提到】
: 不错啊,剪掉5% BCB,卖掉狗头,就不到800刀了
avatar
G*e
23
欢迎老娘到P+逛一逛。
avatar
p*n
24
这个是不是没法online order?
当年买K10D时候用过那个,真麻烦啊

【在 m*****e 的大作中提到】
: 贱人卡你都忘了。
: 8折呀。

avatar
c*q
26
哈哈~~谢谢您的欢迎~我在思索买什么P+的镜头呢~

【在 G*******e 的大作中提到】
: 欢迎老娘到P+逛一逛。
avatar
d*0
27
跌到500再入
avatar
G*e
28
21mm 饼干。

【在 c******q 的大作中提到】
: 哈哈~~谢谢您的欢迎~我在思索买什么P+的镜头呢~
avatar
c*q
29
冏..那要等新机出来吧?
P+全幅遥遥无期阿....

【在 d*****0 的大作中提到】
: 跌到500再入
avatar
c*q
30
胶片机也可以用么?

【在 G*******e 的大作中提到】
: 21mm 饼干。
avatar
G*e
31
没试过, 印象中有暗角。

【在 c******q 的大作中提到】
: 胶片机也可以用么?
avatar
d*0
32
饼干装在小机器上都嫌小,全副大机器更没话说了。

【在 c******q 的大作中提到】
: 胶片机也可以用么?
avatar
h*g
33
胶片机体积不比数码机大,要薄不少

【在 d*****0 的大作中提到】
: 饼干装在小机器上都嫌小,全副大机器更没话说了。
相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。