Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #88244

Re: Sudoku solver

References (1 earlier) <4e81bdb9-52db-46e6-b449-d4241cb2a3f2@googlegroups.com> <87twx8amww.fsf@elektro.pacujo.net> <82e7c5b9-2f0f-405b-859c-b74916c475e0@googlegroups.com> <R6HRw.1255136$4b6.945049@fx44.am4> <55176c2c$0$13009$c3e8da3$5496439d@news.astraweb.com>
Date 2015-03-29 15:10 +1100
Subject Re: Sudoku solver
From Chris Angelico <rosuav@gmail.com>
Newsgroups comp.lang.python
Message-ID <mailman.297.1427602256.10327.python-list@python.org> (permalink)

Show all headers | View raw


On Sun, Mar 29, 2015 at 2:06 PM, Steven D'Aprano
<steve+comp.lang.python@pearwood.info> wrote:
> On Sun, 29 Mar 2015 10:50 am, BartC wrote:
>
>> (X is my own interpreted language, which is where my interest in this
>> is. This had been generally faster than Python until PyPy came along. It
>> does however use a pure byte-code interpreter, so the result is not too
>> bad.
>>
>> But using X *and* my own brute-force algorithm, the same puzzle took 2
>> seconds to solve - faster than C!
>
> But, when you tell me that your very own personal interpreted language,
> which I assume nobody else has worked on, is 40% faster than optimized C,
> my first reaction is to expect that you've probably made a mistake
> somewhere. I would have the same reaction if somebody casually dropped into
> a conversation that they happened to beat Usain Bolt's 100m personal best
> of 9.58 seconds by almost four seconds. While carrying a 20kg backpack.

I think you're misreading the stats. The first table compares
languages, all using the same algorithm, and in that, C beat X ten to
one, unoptimized. The second figure, when X took only 2 seconds, was
demonstrating the massive improvement that the algorithmic change
(from "the OP's algorithm" to "[BartC's] own brute-force algorithm")
achieved. For comparison, that's like casually dropping into
conversation that you happened to drive a car faster than Usain Bolt's
personal best. :)

ChrisA

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-25 13:39 +0200
  Re: Sudoku solver John Ladasky <john_ladasky@sbcglobal.net> - 2015-03-25 11:44 -0700
    Re: Sudoku solver Ian Kelly <ian.g.kelly@gmail.com> - 2015-03-25 13:05 -0600
    Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-25 21:37 +0200
      Re: Sudoku solver Ian Kelly <ian.g.kelly@gmail.com> - 2015-03-25 14:09 -0600
        Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-25 22:31 +0200
          Re: Sudoku solver Chris Angelico <rosuav@gmail.com> - 2015-03-26 09:40 +1100
          Re: Sudoku solver Ian Kelly <ian.g.kelly@gmail.com> - 2015-03-25 18:07 -0600
            Re: Sudoku solver BartC <bc@freeuk.com> - 2015-03-27 20:04 +0000
          Re: Sudoku solver Abhiram R <abhi.darkness@gmail.com> - 2015-03-26 08:26 +0530
          Re: Sudoku solver Ian Kelly <ian.g.kelly@gmail.com> - 2015-03-25 21:24 -0600
          Re: Sudoku solver Abhiram R <abhi.darkness@gmail.com> - 2015-03-26 08:58 +0530
            Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-26 14:13 +0200
              Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-26 16:15 +0200
          Re: Sudoku solver albert@spenarnc.xs4all.nl (Albert van der Horst) - 2015-04-10 23:10 +0000
      Re: Sudoku solver Sayth <flebber.crue@gmail.com> - 2015-03-27 20:39 -0700
        Re: Sudoku solver BartC <bc@freeuk.com> - 2015-03-28 23:50 +0000
          Re: Sudoku solver Chris Angelico <rosuav@gmail.com> - 2015-03-29 11:12 +1100
            Re: Sudoku solver BartC <bc@freeuk.com> - 2015-03-29 21:59 +0100
              Re: Sudoku solver Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-03-29 22:19 +0100
                Re: Sudoku solver BartC <bc@freeuk.com> - 2015-03-29 22:59 +0100
          Re: Sudoku solver Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2015-03-29 14:06 +1100
            Re: Sudoku solver Chris Angelico <rosuav@gmail.com> - 2015-03-29 15:10 +1100
              Re: Sudoku solver Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2015-03-29 21:35 +1100
                Re: Sudoku solver Chris Angelico <rosuav@gmail.com> - 2015-03-29 21:54 +1100
                Re: Sudoku solver BartC <bc@freeuk.com> - 2015-03-29 13:01 +0100
                Re: Sudoku solver BartC <bc@freeuk.com> - 2015-03-29 16:23 +0100
            Re: Sudoku solver Christian Gollwitzer <auriocus@gmx.de> - 2015-03-29 09:57 +0200
              Re: Sudoku solver BartC <bc@freeuk.com> - 2015-03-30 11:54 +0100
            Re: Sudoku solver BartC <bc@freeuk.com> - 2015-03-29 12:25 +0100
              Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-29 21:03 +0300
                Re: Sudoku solver Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-03-29 19:26 +0100
                Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-29 21:33 +0300
                Re: Sudoku solver BartC <bc@freeuk.com> - 2015-03-29 22:11 +0100
                Re: Sudoku solver Ian Kelly <ian.g.kelly@gmail.com> - 2015-03-30 00:50 -0600
                Re: Sudoku solver Christian Gollwitzer <auriocus@gmx.de> - 2015-03-30 09:13 +0200
                Re: Sudoku solver Ian Kelly <ian.g.kelly@gmail.com> - 2015-03-30 01:29 -0600
                Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-30 12:16 +0300
                Re: Sudoku solver Dave Angel <davea@davea.name> - 2015-03-30 04:16 -0400
                Re: Sudoku solver Ian Kelly <ian.g.kelly@gmail.com> - 2015-03-30 02:57 -0600
                Re: Sudoku solver Chris Angelico <rosuav@gmail.com> - 2015-03-30 20:13 +1100
          Re: Sudoku solver Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-03-29 22:21 +0100
            Re: Sudoku solver BartC <bc@freeuk.com> - 2015-03-29 23:17 +0100
              Re: Sudoku solver Seymore4Head <Seymore4Head@Hotmail.invalid> - 2015-03-29 21:40 -0400
  Re: Sudoku solver Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2015-03-26 09:50 +1100
    Re: Sudoku solver Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-03-25 23:04 +0000
      Re: Sudoku solver Christian Gollwitzer <auriocus@gmx.de> - 2015-03-27 07:40 +0100
  Re: Sudoku solver "Frank Millman" <frank@chagford.com> - 2015-03-26 10:19 +0200
    Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-26 14:26 +0200
      Re: Sudoku solver Chris Angelico <rosuav@gmail.com> - 2015-03-26 23:37 +1100
      Re: Sudoku solver Ian Kelly <ian.g.kelly@gmail.com> - 2015-03-26 07:15 -0600
        Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-26 16:23 +0200
          Re: Sudoku solver Ian Kelly <ian.g.kelly@gmail.com> - 2015-03-26 09:06 -0600
            Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-26 17:48 +0200
              Re: Sudoku solver Ian Kelly <ian.g.kelly@gmail.com> - 2015-03-26 10:20 -0600
                Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-26 18:47 +0200
      Re: Sudoku solver Dave Angel <davea@davea.name> - 2015-03-26 10:14 -0400
      Re: Sudoku solver Chris Angelico <rosuav@gmail.com> - 2015-03-27 01:41 +1100
      Re: Sudoku solver Dave Angel <davea@davea.name> - 2015-03-26 11:03 -0400
        Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-26 17:42 +0200
          Re: Sudoku solver Pete Forman <petef4+usenet@gmail.com> - 2015-03-26 22:24 +0000
      Re: Sudoku solver Chris Angelico <rosuav@gmail.com> - 2015-03-27 02:21 +1100
      Re: Sudoku solver Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2015-03-26 20:42 -0400
      Re: Sudoku solver Dave Angel <davea@davea.name> - 2015-03-27 09:14 -0400
      Re: Sudoku solver Chris Angelico <rosuav@gmail.com> - 2015-03-28 00:25 +1100
      Re: Sudoku solver "Frank Millman" <frank@chagford.com> - 2015-03-27 15:35 +0200
        Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-27 15:56 +0200
          Re: Sudoku solver Dave Angel <davea@davea.name> - 2015-03-27 10:09 -0400
            Re: Sudoku solver sohcahtoa82@gmail.com - 2015-03-27 11:18 -0700
              Re: Sudoku solver Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2015-03-28 12:46 +1100
            Re: Sudoku solver Larry Hudson <orgnut@yahoo.com> - 2015-03-27 16:48 -0700
          Re: Sudoku solver Chris Angelico <rosuav@gmail.com> - 2015-03-28 01:07 +1100
          Re: Sudoku solver Chris Angelico <rosuav@gmail.com> - 2015-03-28 01:19 +1100
            Re: Sudoku solver Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2015-03-28 14:13 +1300
            Re: Sudoku solver Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2015-03-28 12:40 +1100
              Re: Sudoku solver Ian Kelly <ian.g.kelly@gmail.com> - 2015-03-28 02:24 -0600
          Re: Sudoku solver Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-03-27 16:03 +0000
          Re: Sudoku solver Virgil Stokes <vs@it.uu.se> - 2015-03-28 19:36 +0100
      Re: Sudoku solver Dave Angel <davea@davea.name> - 2015-03-27 09:48 -0400
      Re: Sudoku solver Dave Angel <davea@davea.name> - 2015-03-27 09:52 -0400
      Re: Sudoku solver Chris Angelico <rosuav@gmail.com> - 2015-03-28 00:58 +1100
  Re: Sudoku solver mr.smittye@gmail.com - 2015-03-29 16:39 -0700
    Re: Sudoku solver Marko Rauhamaa <marko@pacujo.net> - 2015-03-30 12:24 +0300

csiph-web