请教遗传高手:关于weak alleles双突变结果的解释# Biology - 生物学
A*r
1 楼
原题如下:
9.7 A circus is designing an act consisting of a tower of people
standing atop one another’s shoulders. For practical and aesthetic reasons,
each person must be both shorter and lighter than the person below her.
Given the heights and weights of each person in the circus, what is the
largest possible number of people in such a tower?
我理解的就是要先sort一下,然后再在weight里找LIS就好了,这个要用
DP需要额外保存一数组,最好的复杂度是O(nlogn).
CareerCup给出的算法貌是不对的,从每一个unfit开始重新计算LIS
,只有O(n)的样子, 还是我理解有误?
9.7 A circus is designing an act consisting of a tower of people
standing atop one another’s shoulders. For practical and aesthetic reasons,
each person must be both shorter and lighter than the person below her.
Given the heights and weights of each person in the circus, what is the
largest possible number of people in such a tower?
我理解的就是要先sort一下,然后再在weight里找LIS就好了,这个要用
DP需要额外保存一数组,最好的复杂度是O(nlogn).
CareerCup给出的算法貌是不对的,从每一个unfit开始重新计算LIS
,只有O(n)的样子, 还是我理解有误?