Subject: Re: newbie asks: is there a better way to declare arrays?
From: Erik Naggum <>
Date: Fri, 01 Mar 2002 16:34:37 GMT
Newsgroups: comp.lang.lisp
Message-ID: <>

* synthespian <>
| I want to declare a 4 X 4 array

  "Declare"?  You seem to want to construct it.

| Is there another way by which I could declare the first line of the array?

  Is there some word in your native tongue that looks a lot like "declare",
  but which has a sensible meaning in your context?  I find it very odd,
  even when I try to interpret this is in "Java/C++ mode", because even in
  those languages, a declaration cannot initialize anything; a definition
  might, and a call to a run-time constructor

| mean, in a less tedious way? E.g., declaring the whole list of the
| Nominativ at once: (list 'der 'die 'das 'die) and fit it into the array?

  See the specification of make-array and look for the :initial-contents
  argument in particular.  You might notice something quite interesting
  about how the syntax for arrays work with how you initialize them.

  In a fight against something, the fight has value, victory has none.
  In a fight for something, the fight is a loss, victory merely relief.