答案在此, 小括号中1, 2, 3为第几次称

contact (Contact)
本文发表在 rolia.net/zh 相约加拿大网上社区枫下论坛
A = {1, 2, 3, 4}
B = {5, 6, 7, 8}
C = {9, 10, 11, 12, 13}

if (A == B) (1)
{
answer in 9, 10, 11, 12, 13

D = {1, 9, 10}
E = {2, 5, 11}

if (D == E) (2)
{
answer in 12 or 13

if (1 == 12) (3)
answer is 13
else (3)
answer is 12
}
else (2)
{
answer in 9 or 10 or 11

if (9 == 10) (3)
{
answer is 11
}
else (3)
{
answer is 9 or 10

if (D > E) (2)
{
if (9 > 10) (3)
answer is 9 because D > E
else (3)
answer is 10 because D > E
}
else (2)
{
same as D > E
}
}
}
}
else (1)
{
if (A > B) (1)
{
F = {1, 5, 6}
G = {2, 7, 9}

if (F == G) (2)
{
answer in 3 or 4 or 8

if (3 == 4) (3)
answer is 8
else if (3 > 4) (3)
answer is 3 because A > B
else (3)
answer is 4 because A > B
}
else if (F > G) (2)
{
answer in 1 or 7, same as above answer in 12 or 13
}
else (2)
{
answer in 2 or 5 or 6, same as above answer in 9, 10, 11
}
}
else (1)
{
same as A > B
}
}
更多精彩文章及讨论,请光临枫下论坛. 网址: rolia.net/zh
(#238439@0)
2001-10-26 -05:00

回到话题: 不是微软试题,13个球,有一个球和其他的重量不一样,外观一样。用一个天平称三次,把那个球找出来。你能做到吗?嘿嘿。。。

回到论坛: HOME枫下论坛枫下论坛主坛枫下沙龙谈天说地

URL:   
http://www.rolia.net/zh/post.php?f=0&p=238439