Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
标程错了?还是我没读懂题目?WA了半天,找了个标程来测试数据,随机生成了下面这组数据 1 BBRRBRGGRBBBRGR BRBGGGGBGRRGBBB BGBGGRBRRGBGBGG BGRBRBBRGGRBGRR RBBGGRRBRRBGBGR BGGGBGBGRGBRBBR GGBRBRBGGBGBRGG GGBBGBBBRGGBGGG RGBGBBGRBRBRGRR RGBRGRBGGBBRBBG 标程(已AC)得出的答案,前几步是: Game 1: Move 1 at (4,1): removed 11 balls of color G, got 81 points. Move 2 at (1,2): removed 11 balls of color B, got 81 points. Move 3 at (3,5): removed 7 balls of color B, got 25 points. Move 4 at (3,13): removed 6 balls of color G, got 16 points. Move 5 at (1,12): removed 10 balls of color R, got 64 points. Move 6 at (2,10): removed 12 balls of color B, got 100 points. Move 7 at (4,10): removed 6 balls of color B, got 16 points. Move 8 at (1,10): removed 6 balls of color G, got 16 points. Move 9 at (1,13): removed 6 balls of color G, got 16 points. 。。。。。。 我的程序得出的答案是(为了测试把每一步移动后的状态打印出来了): Move 1 at (3,1): removed 11 balls of color G, got 81 points. RGGRBBBRGR R BGGBGRRGBBB B BRGRBRRGBGBGG B BGGBBRGGRBGRR B RGRRRBRRBGBGR BBBBBGBGRGBRBBR RRBRBRBGGBGBRGG BGBBGBBBRGGBGGG RGBGBBGRBRBRGRR RBBRGRBGGBBRBBG Move 2 at (5,1): removed 15 balls of color B, got 169 points. RGGRBBBRGR GGBGRRGBBB RBRRGBGBGG BBBRGGRBGRR RGRRBRRBGBGR GGGBGRGBRBBR R RGRRBGGBGBRGG BRBRGBBBRGGBGGG RGBGBBGRBRBRGRR RGRRGRBGGBBRBBG Move 3 at (2,5): removed 7 balls of color B, got 25 points. RBBBRGR GGRRGBBB R BRGBGBGG GGRGGRBGRR RBRGRRRBGBGR GGBBBRGBRBBR R RGGRBGGBGBRGG BRBRRGRGRGGBGGG RGBGGRGRBRBRGRR RGRRGRBGGBBRBBG Move 4 at (2,13): removed 6 balls of color G, got 16 points. RBBB GGRRG R BRGBGRGR GGRGGRBBBB RBRGRRRBGBGG GGBBBRGBRGRR R RGGRBGGBGBBGR BRBRRGRGRGGBBBR RGBGGRGRBRBRRRR RGRRGRBGGBBRBBG Move 5 at (1,12): removed 9 balls of color R, got 49 points. RBB GGRR R BRGBB GGRGGRGR RBRGRRRBGBG GGBBBRGBBBB R RGGRBGGBGGGGR BRBRRGRGRGGRBGB RGBGGRGRBRBBBBG RGRRGRBGGBBBBBG 也不用看得太多,看第一步就出了问题。第一次移动两个程序输出的结果一样的,但是移动后的状态应该就是我的程序打印出来的那样,那么第二步要移的应该是B,15个球,但是标程却给出11个球,这不是显然错了吗。而且题目说所处族大小相同的球里应该选最左的,其次再选最下方的,那第一步应该是选(3,1)而不是(4,1),标程为什么要选(4,1)?哪位高手来给我解释一下。。。。。。 Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator