From: ··········@gmail.com
Subject: tables?
Date: 
Message-ID: <1112983181.076136.97930@l41g2000cwc.googlegroups.com>
hi, which data structure is best to be used for a table? a 2
dimensional table.. and if a 2 dimensional table is the way to go, how
would u do that in lisp? 

thanks alot :D

From: Sam Steingold
Subject: Re: tables?
Date: 
Message-ID: <uhdihw3hm.fsf@gnu.org>
> *  <··········@tznvy.pbz> [2005-04-08 10:59:41 -0700]:
>
> hi, which data structure is best to be used for a table? a 2
> dimensional table..

what are you trying to do specifically?

> and if a 2 dimensional table is the way to go, how
> would u do that in lisp?

(make-array '(10 100) ...)
<http://www.lisp.org/HyperSpec/Body/fun_make-array.html>
<http://www.lisp.org/HyperSpec/Body/acc_aref.html>

-- 
Sam Steingold (http://www.podval.org/~sds) running w2k
<http://www.camera.org> <http://www.iris.org.il> <http://www.mideasttruth.com/>
<http://www.jihadwatch.org/> <http://www.honestreporting.com>
I haven't lost my mind -- it's backed up on tape somewhere.
From: ··········@gmail.com
Subject: Re: tables?
Date: 
Message-ID: <1113062378.446460.274800@f14g2000cwb.googlegroups.com>
i'm trying to do a "magic square" checker.. a magic square is where the
sum of the numbers in rows = the sum of the numbers in columns = the
sum of the numbers in diagonals.. i thought i'd do something like a
magic square generation program  also along with a checker, originally
i did this in Java, mmm.. the code looked ugly, and i went back to it
after 2 monthes, i can't understand half of wat i wrote.. so i thought
if i can do a better program in lisp or not :D sorry for the delay in
response :D
From: Barry Margolin
Subject: Re: tables?
Date: 
Message-ID: <barmar-5BCCD8.21594609042005@comcast.dca.giganews.com>
In article <························@f14g2000cwb.googlegroups.com>,
 ··········@gmail.com wrote:

> i'm trying to do a "magic square" checker.. a magic square is where the
> sum of the numbers in rows = the sum of the numbers in columns = the
> sum of the numbers in diagonals.. i thought i'd do something like a
> magic square generation program  also along with a checker, originally
> i did this in Java, mmm.. the code looked ugly, and i went back to it
> after 2 monthes, i can't understand half of wat i wrote.. so i thought
> if i can do a better program in lisp or not :D sorry for the delay in
> response :D

It seems like a 2-dimensional array is the obvious data structure to use 
for this.  What's the problem?

-- 
Barry Margolin, ······@alum.mit.edu
Arlington, MA
*** PLEASE post questions in newsgroups, not directly to me ***
From: GP lisper
Subject: Re: tables?
Date: 
Message-ID: <1113115802.2f1c1163f10f9d886c43935bdf8c3df0@teranews>
On 9 Apr 2005 08:59:38 -0700, <··········@gmail.com> wrote:
>
> i'm trying to do a "magic square" checker.. a magic square is where the
> sum of the numbers in rows = the sum of the numbers in columns = the
> sum of the numbers in diagonals.. i thought i'd do something like a
> magic square generation program  also along with a checker, originally
> i did this in Java, mmm.. the code looked ugly, and i went back to it
> after 2 monthes, i can't understand half of wat i wrote.. so i thought
> if i can do a better program in lisp or not :D sorry for the delay in
> response :D

CLisp offers a runnable version of SCREAMER, which you can use to
simply create magic squares.


-- 
Everyman has three hearts;
one to show the world, one to show friends, and one only he knows.