let the 12 balls be numbered 1,2,3,4,5,...,12
# p3 M) D* T; \2 }' vweight 1234 with 56785.39.217.767 M( ~1 S6 O | G8 a& p
case 1
( |; F' `% t* T: G3 J7 a4 Vif 1234>5678, then weight 125 with 678
1 d+ P$ R4 J) X7 i. P1 d/ v5.39.217.76if 125>678, then weight 1 with 2公仔箱論壇# [' n9 G( Z' t' [" a/ D
if 1>2 it is 1, if 1=2 it is 5, if 1<2 it is 2
3 n* O6 K& L$ L! O6 Rif 125=678, then weight 3 with 9
# r ~/ g3 L+ F1 s4 c5 @3 x7 cif 3=9 it is 4, else it is 3
" ^) J2 t( Z# p( ^/ nTVBNOW 含有熱門話題,最新最快電視,軟體,遊戲,電影,動漫及日常生活及興趣交流等資訊。if 125<678, then ewight 3 with 4
% r4 T, r/ \" W( \: ] W1 `/ }公仔箱論壇if 3>4 it is 3, if 3=4, it is 5, if 3<4, it is 4
/ D b O: y! f: g: M% f2 D% C% ]3 Z, `. i$ B
case 2
3 g; D4 k Y) b" P0 \: l$ t. r5.39.217.76repeat above for 5678 instead of 1234 if 1234<5678
; e+ P* `( @0 |5.39.217.765.39.217.764 }1 c. B$ `% G$ v, o! g
case 3公仔箱論壇3 D% \/ W( O6 t5 O7 X: n/ K# }5 g
1234=5678, this case u only have 9 10 11 12 as possible, this is easy enough that i don't need to explainTVBNOW 含有熱門話題,最新最快電視,軟體,遊戲,電影,動漫及日常生活及興趣交流等資訊。5 @7 n$ K3 E8 A! {5 X8 s
TVBNOW 含有熱門話題,最新最快電視,軟體,遊戲,電影,動漫及日常生活及興趣交流等資訊。! j/ k9 N( h8 T. @( _2 v
[ 本帖最後由 l0709394 於 2007-5-8 10:15 AM 編輯 ] |