w*9
2 楼
49 辆赛车. Assume for each one, it travels the track in the same amount
of time every time. Also assume no two finish the track in the same
amount of time. Suppose you have 7 tracks, but no timer. Design races to
find the 25-th fastest with minimal number of races.
mitbbs 曾经讨论过这个题,当时没有注意,现在已经搜索不到了。 欢迎大家讨论讨论
想了一个解法,不清楚还有没有更优解,特来请教
7次, 跑出 A1, A2, .... A7
B1, B2, ... B7
..
..
G1, G2, .....G7
第8次, 取 A4, B4, C4, .....G4
不失一般性,设A4为第一,B4为第二....
这样, A1, A2, A3, A4, B1, B2, 肯定在前24名(包括第24名)
再跑19次得到第25名
共需要 7 + 1 + 19 = 27次
of time every time. Also assume no two finish the track in the same
amount of time. Suppose you have 7 tracks, but no timer. Design races to
find the 25-th fastest with minimal number of races.
mitbbs 曾经讨论过这个题,当时没有注意,现在已经搜索不到了。 欢迎大家讨论讨论
想了一个解法,不清楚还有没有更优解,特来请教
7次, 跑出 A1, A2, .... A7
B1, B2, ... B7
..
..
G1, G2, .....G7
第8次, 取 A4, B4, C4, .....G4
不失一般性,设A4为第一,B4为第二....
这样, A1, A2, A3, A4, B1, B2, 肯定在前24名(包括第24名)
再跑19次得到第25名
共需要 7 + 1 + 19 = 27次
a*c
4 楼
the problem doesn't look like it's set up right. needs more constraints to
make a meaningful problem.
Does the original question say you can't race 49 cars all at once?
make a meaningful problem.
Does the original question say you can't race 49 cars all at once?
n*o
5 楼
麻辣隔壁的,刚跑完马拉松回来,就坐沙发领包子,爽
j*4
6 楼
use median finding algorithm
【在 w**********9 的大作中提到】![](/moin_static193/solenoid/img/up.png)
: 49 辆赛车. Assume for each one, it travels the track in the same amount
: of time every time. Also assume no two finish the track in the same
: amount of time. Suppose you have 7 tracks, but no timer. Design races to
: find the 25-th fastest with minimal number of races.
: mitbbs 曾经讨论过这个题,当时没有注意,现在已经搜索不到了。 欢迎大家讨论讨论
: 想了一个解法,不清楚还有没有更优解,特来请教
: 7次, 跑出 A1, A2, .... A7
: B1, B2, ... B7
: ..
: ..
【在 w**********9 的大作中提到】
![](/moin_static193/solenoid/img/up.png)
: 49 辆赛车. Assume for each one, it travels the track in the same amount
: of time every time. Also assume no two finish the track in the same
: amount of time. Suppose you have 7 tracks, but no timer. Design races to
: find the 25-th fastest with minimal number of races.
: mitbbs 曾经讨论过这个题,当时没有注意,现在已经搜索不到了。 欢迎大家讨论讨论
: 想了一个解法,不清楚还有没有更优解,特来请教
: 7次, 跑出 A1, A2, .... A7
: B1, B2, ... B7
: ..
: ..
a*c
8 楼
best case 10 races with 1/19 chance.
don't know about worst case, 19? there's probably room for improvement here.
don't know about worst case, 19? there's probably room for improvement here.
o*o
13 楼
cong!
h*w
14 楼
恭喜,这才是真正的BSO
b*n
19 楼
吃
l*e
24 楼
恭喜恭喜~ chi
g*f
25 楼
chi
f*e
26 楼
chi
cong!!!
cong!!!
b*d
29 楼
恭喜
z*t
30 楼
来,来,给俺来一笼
m*s
34 楼
chi!!
j*l
35 楼
chi
f*m
36 楼
恭喜!谢谢包子
s*n
37 楼
chi!
j*o
38 楼
排包子
o*n
39 楼
chi baozi!
cong!
cong!
w*x
40 楼
吃!
h*i
41 楼
祝贺!
M*i
44 楼
chi
d*u
45 楼
还有chi吗 祝贺
a*9
46 楼
恭喜恭喜~ chi
t*g
47 楼
Re
m*s
48 楼
cong
m*7
49 楼
虎肉V5!
pai
pai
s*f
50 楼
chi
cong
cong
e*7
51 楼
cong!!!
U*8
52 楼
Cong!
GXGX!
GXGX!
b*h
53 楼
恭喜恭喜!吃包子
d*a
54 楼
恭喜恭喜!
h*0
55 楼
能透漏一下小钱是多少?
a*k
61 楼
Cong
d*u
62 楼
ding! cong!
v*o
66 楼
cong!
l*e
67 楼
虎教授太牛了 一下发这么大的包子 以后我是虎粉 :)
s*e
68 楼
“转帐失败, 24小时内转帐金额不能大于1000伪币”
不好意思。明天接着转包子。如果漏了哪个朋友,请短信通知我。
不好意思。明天接着转包子。如果漏了哪个朋友,请短信通知我。
z*s
72 楼
恭喜恭喜!吃
[在 stoppingtime (停时) 的大作中提到:]
:今天破例高调一把。发包子!
:
:...........
[在 stoppingtime (停时) 的大作中提到:]
:今天破例高调一把。发包子!
:
:...........
r*9
75 楼
还有吗?无论如何恭喜恭喜
t*r
78 楼
吃
j*l
79 楼
虎教授霸气!第一次一口气吃了五个肉馅大包差点噎着
j*u
81 楼
恭喜
u*n
82 楼
Cong!
S*a
83 楼
有没有吃了?
r*t
84 楼
chi
s*e
86 楼
恭喜恭喜
还有包子没?
还有包子没?
m*7
87 楼
排!
p*e
88 楼
恭喜!
相关阅读
电面感觉很烂,onSite感觉很好请看看这个OPT加急回复是否成功了?二爷的站内信箱总是满的?Intel的墨西哥分部如何,值得去吗G是怎样确定package的L家面经&求问L家host manager interviewlayoff的gap会被发现吗?请教一道g算法题报offer面对来势凶猛的印度,国人该怎么办?现在进药厂做分析能拿多少银子求教:要不要接这个contract观察到湾区双码工趋势 (转载)OPT 问题OPT四年不用交MED税,爽死问工资情况应该怎么说?What's the salary/benefit of this jobLinkedIn面试这么变态啊!推荐一本好书求问F家offer面试时用动规,要求对空间进行优化吗?