[Haskell-cafe] How to represent a board?
Carter Schonwald
carter.schonwald at gmail.com
Fri Jun 20 16:09:47 UTC 2014
Unless you're dealing with a board with millions of positions or more,
sparse matrices don't matter.
The array package has support for 2d arrays.
I've my own pretty fancy multi dim array tooling in the works, but for your
use case just use array package
On Friday, June 20, 2014, Chris Warburton <chriswarbo at googlemail.com> wrote:
> Corentin Dupont <corentin.dupont at gmail.com <javascript:;>> writes:
>
> > Instead of encoding the board, I would encode the position of the pieces:
> > there is usually much less pieces than squares.
>
> Possibly useful: http://en.wikipedia.org/wiki/Sparse_matrix
>
> Cheers,
> Chris
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org <javascript:;>
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20140620/14daffb3/attachment.html>
More information about the Haskell-Cafe
mailing list