由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
JobHunting版 - 昨晚的Google Intern Interview
相关主题
bb面试的25批马问题internship overlap period (转载)
25匹马找前5名的老题答案是啥?被雷BF事件后续, 哈哈, 我们结婚了 (转载)
赛马题一个Google面试题
问一道Brain Teaser题[合集] 被雷BF事件后续, 哈哈, 我们结婚了 (转载)
两道题facebook on site后多久给消息啊
请问49horse的答案问个算法题, 关于区间 overlap的
昨天面试的题目求overlap的rectagales
Amazon 两轮电话面经 及 design问题请教Divide Two Integers
相关话题的讨论汇总
话题: each话题: set话题: races话题: race话题: horses
进入JobHunting版参与讨论
1 (共1页)
P*A
发帖数: 189
1
有生一来第一次interview,题很简单,但是表现的很糟糕;看来需要补的功课还很多
啊:)
1. 在n x n matrix中查找一个元素,row都是有序的。
2. 25匹赛马,5条跑道,最少赛几次找出最快的3匹马。
3. (Coding)一个binary sequence,找一个划分位置尽量使1分在一边,0分在另一边
;混在0堆
里面的1和混在1里面的0都是error。设计算法使error最小。
第一位阿三兄还问了些数据结构的问题,很窘的是我居然吧heap解释成binary search
tree了。
第二位是个名校的fresh phd,他跟我说是第一次面人,还聊了聊research,由于面的
不好,我都想
赶快挂电话回家睡觉了(人在新加坡,已经半夜了),他还非跟我聊(估计是安慰我一
下,哈)。
两大哥都挺nice的,让你明明知道面的不好,没啥戏了,心情也不会难受。
主要是没办法静下心来思考,经验少,基础也不好。
祝大家都有好offer:)
h**k
发帖数: 3368
2
1.对每个row做binary search?有更好的方法么?
2.突然发现这题其实是young tableau的一个应用。
3.应该就是线性扫描一遍了,

search

【在 P*A 的大作中提到】
: 有生一来第一次interview,题很简单,但是表现的很糟糕;看来需要补的功课还很多
: 啊:)
: 1. 在n x n matrix中查找一个元素,row都是有序的。
: 2. 25匹赛马,5条跑道,最少赛几次找出最快的3匹马。
: 3. (Coding)一个binary sequence,找一个划分位置尽量使1分在一边,0分在另一边
: ;混在0堆
: 里面的1和混在1里面的0都是error。设计算法使error最小。
: 第一位阿三兄还问了些数据结构的问题,很窘的是我居然吧heap解释成binary search
: tree了。
: 第二位是个名校的fresh phd,他跟我说是第一次面人,还聊了聊research,由于面的

Z*****Z
发帖数: 723
3
3. 一遍是怎么做到的?我觉得怎么也得2、3遍?

【在 h**k 的大作中提到】
: 1.对每个row做binary search?有更好的方法么?
: 2.突然发现这题其实是young tableau的一个应用。
: 3.应该就是线性扫描一遍了,
:
: search

z****n
发帖数: 1379
4
两遍吧
就是每一个位置(一遍),算下error(需要左右scan,第二遍),选error最小的位置

【在 Z*****Z 的大作中提到】
: 3. 一遍是怎么做到的?我觉得怎么也得2、3遍?
p*****h
发帖数: 21
5
弱弱地问下,young tableau是什么,有通俗点的做法么?
P*A
发帖数: 189
6
1我也是说这个,但他说应该有更好的。我觉得应该把row之间在联系一下,但是没想出来
3咋一遍做好,能细说说么

【在 h**k 的大作中提到】
: 1.对每个row做binary search?有更好的方法么?
: 2.突然发现这题其实是young tableau的一个应用。
: 3.应该就是线性扫描一遍了,
:
: search

l*****a
发帖数: 14598
7
for(i=0;i {
//a is how many 1's appeared till Array[i]
//b is how many 0's appeared till Array[i]
//if we split the array after a[i],then the error number in the left
side is b(leave 1 on the left) or a(leave 0 on the left)
//for another side, assume there are c 1 and d 0,then the error umber
is c(leave1 on the left) or d(leave 0 on the left) ,but pay attention that
a+c is fixed and b+d is fixed,
so c=NumOne-a and d=NumZero-b
//so b+c=numOne+b-a, a+d=NumZero+a-b
//what

【在 P*A 的大作中提到】
: 1我也是说这个,但他说应该有更好的。我觉得应该把row之间在联系一下,但是没想出来
: 3咋一遍做好,能细说说么

l*****a
发帖数: 14598
8
there is no any condition between rows..
is it possible that u lost some conditions?
such as the famous issue:row/column are all sorted

出来

【在 P*A 的大作中提到】
: 1我也是说这个,但他说应该有更好的。我觉得应该把row之间在联系一下,但是没想出来
: 3咋一遍做好,能细说说么

s*****n
发帖数: 162
9
See: http://en.allexperts.com/q/Puzzle-Solving-1841/f/Puzzle-5.htm
Divide the set of 25 horses into 5 non-overlapping sets of 5 horses each.
Have a race each for all the horses in each set. This makes it a total of 5
races, one for each set.
Now, have a race for the winners of each of the previous 5 races. This makes
it a total of 6 races.
Observe the position of each horse in the 6th race and correspondingly
number the sets. i.e. the set of the winner of 6th race will be said to be
set no. 1 wh
s*****n
发帖数: 162
10
See: http://en.allexperts.com/q/Puzzle-Solving-1841/f/Puzzle-5.htm
Divide the set of 25 horses into 5 non-overlapping sets of 5 horses each.
Have a race each for all the horses in each set. This makes it a total of 5
races, one for each set.
Now, have a race for the winners of each of the previous 5 races. This makes
it a total of 6 races.
Observe the position of each horse in the 6th race and correspondingly
number the sets. i.e. the set of the winner of 6th race will be said to be
set no. 1 wh
r********e
发帖数: 122
11
For question 2
Let every horse just run for one time and record the time. You will have top
3.
So 5 races in total, is this right?
f*********5
发帖数: 576
12
there is no way to record the time
just be able to know the order
otherwise,isn't it too simple?

top

【在 r********e 的大作中提到】
: For question 2
: Let every horse just run for one time and record the time. You will have top
: 3.
: So 5 races in total, is this right?

c******f
发帖数: 2144
13
恩 congs
1 (共1页)
进入JobHunting版参与讨论
相关主题
Divide Two Integers两道题
问一道 Interviewstreet 上的题 (JAVA)请问49horse的答案
求助一道FB的高频题non-overlap jobs昨天面试的题目
Apple iCloud 电面Amazon 两轮电话面经 及 design问题请教
bb面试的25批马问题internship overlap period (转载)
25匹马找前5名的老题答案是啥?被雷BF事件后续, 哈哈, 我们结婚了 (转载)
赛马题一个Google面试题
问一道Brain Teaser题[合集] 被雷BF事件后续, 哈哈, 我们结婚了 (转载)
相关话题的讨论汇总
话题: each话题: set话题: races话题: race话题: horses