由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Programming版 - Interview question
相关主题
一FG家常见题 (转载)问一道排序题目
Java: use a HashSet to find the elements that are common in all listsstl的nth_element的复杂度是不是O(N)?
求一本面试书 algorithms for interviews[合集] 未排序的100个数字,如果最快地找出最大的5个?
算法问题[合集] 答案. 未排序的100个数字,如何最快地找出最大的5个
两个矩阵的算法题大矩阵如何转置?
求助一个数据结构的求时间复杂度问题CheckForZero
an interview question请教:distance calculation
javascript的一个问题:不能用loop,不能用library,怎么来remov (转载)a newbie java question (转载)
相关话题的讨论汇总
话题: interview话题: question话题: find话题: grabing话题: cnl
进入Programming版参与讨论
1 (共1页)
c********e
发帖数: 383
1
1) code to find Cnl (possibilities of grabing L elements out of N)
2) how to find the median number using stl , given an integer array.
t****t
发帖数: 6806
2
不会吧,这你不会做?
(1)是要列举每种结果还是算个数目就好了? (是C(n,l)吧?)

【在 c********e 的大作中提到】
: 1) code to find Cnl (possibilities of grabing L elements out of N)
: 2) how to find the median number using stl , given an integer array.

l*********b
发帖数: 8
3

recursive. mark used element, advance the pointer and call itself
nth_element()

【在 c********e 的大作中提到】
: 1) code to find Cnl (possibilities of grabing L elements out of N)
: 2) how to find the median number using stl , given an integer array.

c********e
发帖数: 383
4
no ah..just been asked,
for the first question sorta dynamic programming skill can be applied.
for the second one nth_element. but i am stuck with the run time cost.
the average linear time

【在 t****t 的大作中提到】
: 不会吧,这你不会做?
: (1)是要列举每种结果还是算个数目就好了? (是C(n,l)吧?)

c*****t
发帖数: 1879
5

you must use that algorithm a lot ^_^

【在 l*********b 的大作中提到】
:
: recursive. mark used element, advance the pointer and call itself
: nth_element()

f*z
发帖数: 421
6
第一题题目没看懂,那位给说一下,到底要做什么啊?

【在 c********e 的大作中提到】
: 1) code to find Cnl (possibilities of grabing L elements out of N)
: 2) how to find the median number using stl , given an integer array.

c********e
发帖数: 383
7
n!/(l!(n-l)!)

【在 f*z 的大作中提到】
: 第一题题目没看懂,那位给说一下,到底要做什么啊?
N***m
发帖数: 4460
8
这都什么啊?天书一样啊

【在 c********e 的大作中提到】
: n!/(l!(n-l)!)
l******e
发帖数: 12192
9
你是学数学出身的?
感觉你今天是来挖坑的

【在 N***m 的大作中提到】
: 这都什么啊?天书一样啊
r****t
发帖数: 10904
10
http://en.wikipedia.org/wiki/Combination
高中数学都忘了?

【在 f*z 的大作中提到】
: 第一题题目没看懂,那位给说一下,到底要做什么啊?
N***m
发帖数: 4460
11
我没看懂题目。

【在 l******e 的大作中提到】
: 你是学数学出身的?
: 感觉你今天是来挖坑的

1 (共1页)
进入Programming版参与讨论
相关主题
a newbie java question (转载)两个矩阵的算法题
如何取一个list的第i个element求助一个数据结构的求时间复杂度问题
[合集] 问2个微软电话面试题目an interview question
[合集] 如何得到一个指向STL元素的指针?javascript的一个问题:不能用loop,不能用library,怎么来remov (转载)
一FG家常见题 (转载)问一道排序题目
Java: use a HashSet to find the elements that are common in all listsstl的nth_element的复杂度是不是O(N)?
求一本面试书 algorithms for interviews[合集] 未排序的100个数字,如果最快地找出最大的5个?
算法问题[合集] 答案. 未排序的100个数字,如何最快地找出最大的5个
相关话题的讨论汇总
话题: interview话题: question话题: find话题: grabing话题: cnl