快捷搜索:  汽车  科技

量化测试基础知识(量化岗测试问题与解答系列)

量化测试基础知识(量化岗测试问题与解答系列)解决方案:关键是要认识到,10分钟的人和5分钟的人要一起走,并且他们不能先过河,不然这两个速度慢的人其中一个还必须要再返回来。所以:[ 解答 ]A、B、C、D四个人需要过河,过河的唯一办法是经过一座老桥,这座桥一次最多能容纳两个人。由于天黑,他们没有手电筒不能过桥,而且他们只有一个手电筒,所以每一对都只能以较慢的人的速度行走,并且他们需要尽快过河。A是最慢的,需要10分钟,B需要5分钟,C需要 2分钟,D需要1分钟。他们至少需要多久才能全部过河?请大家先思考。/ Solution /

这一期开始跟大家探讨逻辑推理测试题

/ Question /

[ 问题 ]

过河问题:

A、B、C、D四个人需要过河,过河的唯一办法是经过一座老桥,这座桥一次最多能容纳两个人。由于天黑,他们没有手电筒不能过桥,而且他们只有一个手电筒,所以每一对都只能以较慢的人的速度行走,并且他们需要尽快过河。A是最慢的,需要10分钟,B需要5分钟,C需要 2分钟,D需要1分钟。

他们至少需要多久才能全部过河?请大家先思考。

量化测试基础知识(量化岗测试问题与解答系列)(1)

/ Solution /

[ 解答 ]

解决方案:关键是要认识到,10分钟的人和5分钟的人要一起走,并且他们不能先过河,不然这两个速度慢的人其中一个还必须要再返回来。所以:

C和D应该先过河,(用时2分钟);

然后D返回(用时1分钟);

然后A和B穿过(用时10分钟);

然后C返回(用时2分钟);

C和D再过河(用时2分钟)。

总共需要17分钟。另一种方案,我们可以先让C返回,然后在第二轮让D返回,这也需要17分钟。

/ Question /

River crossing

Four people A B C and D need to get across a river. The only way to cross the river is by an old bridge which holds at most 2 people at a time. Being dark they can’t cross the bridge without a torch of which they only have one. So each pair can only walk.at the speed of the slower person. They need to get all of them across to the other side as quickly as possible. A is the slowest and takes 10 minutes to cross; B takes 5 minutes; C takes 2 minutes; and D takes l minute.

What is the minimum time to get all of them across to the other side?

/ Solution /

Solution: The key point is to realize that the 10- minute person should go with the 5-minute person and this should not happen in the first crossing otherwise one of them have to go back. So C and D should go across first (2min); C and D go across again (2 min).

It takes 17 minutes in total. Alternatively we can send C back first and then D back in the second round. which takes 17 minutes as well.

图片来源于网络,侵删。

欢迎关注公众号:QuantJob

更多资讯,更精准,更高效。

猜您喜欢: