Path: csiph.com!usenet.pasdenom.info!news.redatomik.org!newsfeed.xs4all.nl!newsfeed3a.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.029 X-Spam-Evidence: '*H*': 0.94; '*S*': 0.00; 'squares': 0.07; 'solution,': 0.09; 'cc:addr:python-list': 0.11; 'clear.': 0.16; 'docstring': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'left,': 0.16; 'program?': 0.16; 'python-based': 0.16; 'solver': 0.16; 'url:ics': 0.16; 'url:py': 0.16; 'wrote:': 0.18; 'thu,': 0.19; 'thanks.': 0.20; 'cc:addr:python.org': 0.22; 'logical': 0.24; 'question': 0.24; 'cc:2**0': 0.24; 'holds': 0.26; 'url:edu': 0.26; 'header:In-Reply-To:1': 0.27; 'statement': 0.30; 'message-id:@mail.gmail.com': 0.30; 'purely': 0.31; 'another': 0.32; 'received:google.com': 0.35; 'sequence': 0.36; 'possible': 0.36; 'should': 0.36; 'error.': 0.37; 'two': 0.37; 'solving': 0.38; 'pm,': 0.38; 'solve': 0.60; 'reach': 0.63; 'kind': 0.63; 'here': 0.66; 'between': 0.67; 'mar': 0.68; '26,': 0.68; 'trial': 0.83; '2015': 0.84; 'water.': 0.84; 'to:none': 0.92 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:cc :content-type; bh=z67gOIUa1a6fyMFp8AyVgj48tEkLtyDsYXG1ydHa0T8=; b=A2lH6MLHJhHMNKC/ZdwmcKtzNYyKic0fnu4fRMsmWY5MbRqXRRcyJxAzJGqcNetvF4 zvi9kqk/G2/caj9LQA/6EfOLR8T2N15iciGPxlLd3CTrR7fafi70zilueBRgZ7cYprN9 M5sAuOCa6xy5Sf93k1LCaP0raWsWsdRY2ak5zSMekrTmpPN+woiVav5IvfgmErKXQmGJ EICPdYet+hyo8V4p3IXjMASP2A6a3byqaE0DgsxIxNHRAV6EvHDuKDE7awsMhUZgZmhA UlgFfspgswPRJeQulwX7cpxwXmOfNfdW3R2ZkeSKYro9JjjTwVQvkPd40ADeqySTwUXr c7aA== MIME-Version: 1.0 X-Received: by 10.43.38.144 with SMTP id ti16mr37839803icb.26.1427373430389; Thu, 26 Mar 2015 05:37:10 -0700 (PDT) In-Reply-To: <87fv8sndw1.fsf@elektro.pacujo.net> References: <87r3sdnw5t.fsf@elektro.pacujo.net> <87fv8sndw1.fsf@elektro.pacujo.net> Date: Thu, 26 Mar 2015 23:37:10 +1100 Subject: Re: Sudoku solver From: Chris Angelico Cc: "python-list@python.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.19 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 28 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1427373437 news.xs4all.nl 2844 [2001:888:2000:d::a6]:43181 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:88046 On Thu, Mar 26, 2015 at 11:26 PM, Marko Rauhamaa wrote: > "Frank Millman" : > >> Here is another python-based sudoku solver - >> >> http://www.ics.uci.edu/~eppstein/PADS/Sudoku.py >> >>>From its docstring - >> >> "A proper Sudoku puzzle must have a unique solution, and it should be >> possible to reach that solution by a sequence of logical deductions >> without trial and error. > > I don't think that statement holds water. Trial-and-error is at the > basis of deduction (reductio ad absurdum). The human solver employs it > in their head. The question is, what is the difference between > pen-and-paper and in-your-head for a computer program? Nothing. And solving a Sudoku puzzle - or any other puzzle - should require no guessing. It should be possible to solve purely by logic. Same goes for every other kind of puzzle out there; it's highly unsatisfying to play Minesweeper and get to the end with a block of four squares in a corner, two mines left, and no way of knowing which diagonal has the mines and which is clear. No trial-and-error, thanks. ChrisA