Re: First attempt at a Python prog (Chess)

Discussion in 'Python' started by Tim Golden, Feb 15, 2013.

  1. Tim Golden

    Tim Golden Guest

    On 15/02/2013 13:11, Oscar Benjamin wrote:
    > On 15 February 2013 11:36, Tim Golden <> wrote:
    >> And the "how shall we represent the board?" question is pretty
    >> much the first thing any team asks themselves. And you always
    >> get someone in favour of lists of lists, someone for one long
    >> list,

    >
    > I always get confused when doing this about which of my coordinates
    > needs to be multiplied (i.e. whether I am in Fortran or C order).


    How true. This last time, my team split into two: one half
    to handle the display, the other working on the algorithm. We
    ended up having to draw a really simple diagram on the back of
    an envelope with the x,y pairs written out and pass it back
    and forth as *everyone* kept forgetting which went first.

    >> (Also I seem to remember that the OP was advised earlier precisely
    >> to abandon lists of lists in favour of something else).

    >
    > Actually the suggestion was for the list of lists (instead of a flat list).


    Ah, ok. I'd only followed the thread casually. (And I was too lazy to
    go back and check).

    TJG
     
    Tim Golden, Feb 15, 2013
    #1
    1. Advertising

  2. Tim Golden writes:
    > On 15/02/2013 13:11, Oscar Benjamin wrote:
    > > On 15 February 2013 11:36, Tim Golden wrote:
    > >> And the "how shall we represent the board?" question is pretty
    > >> much the first thing any team asks themselves. And you always get
    > >> someone in favour of lists of lists, someone for one long list,

    > >
    > > I always get confused when doing this about which of my
    > > coordinates needs to be multiplied (i.e. whether I am in Fortran
    > > or C order).

    >
    > How true. This last time, my team split into two: one half to handle
    > the display, the other working on the algorithm. We ended up having
    > to draw a really simple diagram on the back of an envelope with the
    > x,y pairs written out and pass it back and forth as *everyone* kept
    > forgetting which went first.


    Surely you knew to have f1(board, x, y) for getting whatever is at
    (x,y) and f2(store, x, y, wev) for putting wev at (x,y). Why didn't
    you do that?
     
    Jussi Piitulainen, Feb 15, 2013
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Oscar Benjamin

    Re: First attempt at a Python prog (Chess)

    Oscar Benjamin, Feb 13, 2013, in forum: Python
    Replies:
    0
    Views:
    155
    Oscar Benjamin
    Feb 13, 2013
  2. Ian Kelly
    Replies:
    0
    Views:
    124
    Ian Kelly
    Feb 14, 2013
  3. jkn
    Replies:
    1
    Views:
    112
    Dennis Lee Bieber
    Feb 15, 2013
  4. Rick Johnson
    Replies:
    2
    Views:
    174
    Robert Kern
    Apr 30, 2014
  5. Oscar Benjamin

    Re: First attempt at a Python prog (Chess)

    Oscar Benjamin, Feb 15, 2013, in forum: Python
    Replies:
    4
    Views:
    177
    Neil Cerutti
    Feb 19, 2013
Loading...

Share This Page