Re: [問題] sudoku
※ 引述《geo760217 (Tc)》之銘言:
: undo 之後值又變成不合法的了= =
: 這是我的source code
: 真的不知道該在哪裡undo
這麼說吧
在某格每試一個數字 是要這樣做:
(1) 試某數字
(2) 交給後面的人試著往下填
(3) 如果後面的人告訴我此路不通
(3a) 清掉換下一個,回到1
(當然如果都試過了就往上回報此路不通)
(3b) 否則(也就是後面的人告訴我 找到答案了)
就往上回報我找到答案了
黃色的就是你要的東西
--
'Oh, Harry, dont't you see?' Hermione breathed. 'If she could have done
one thing to make absolutely sure that every single person in this school
will read your interview, it was banning it!'
---'Harry Potter and the order of the phoenix', P513
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 192.192.197.116
討論串 (同標題文章)