multidimensional array

Discussion in 'C Programming' started by Owner, Apr 26, 2011.

  1. Owner

    Owner Guest

    I was looking at unicode.c and I've seen code I never seen
    before. Is it possible to write such a code?

    char *unicode[19][21][28] =
    {
    {
    "°¡",
    "°¢",
    ....
    and so on.

    I only seen code like a[][] not a[][][]
     
    Owner, Apr 26, 2011
    #1
    1. Advertising

  2. Owner

    Owner Guest

    And how many dimensions are allowed at maximum in standard?
     
    Owner, Apr 26, 2011
    #2
    1. Advertising

  3. Owner <> writes:

    > And how many dimensions are allowed at maximum in standard?


    Well, there is no definitive answer because of the way the standard is
    worded, but a conforming compiler must accept at least one program with:

    "12 pointer, array, and function declarators (in any combinations)
    modifying an arithmetic, structure, union, or incomplete type in a
    declaration"

    so in your case, 11 array declarators can be used.

    --
    Ben.
     
    Ben Bacarisse, Apr 26, 2011
    #3
    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. Dave Bazell

    slice of multidimensional array

    Dave Bazell, Jul 23, 2003, in forum: Perl
    Replies:
    2
    Views:
    4,134
  2. epigram
    Replies:
    1
    Views:
    10,904
    =?Utf-8?B?c29jaWV0b3BpYS5uZXQ=?=
    Jul 16, 2005
  3. Ben
    Replies:
    8
    Views:
    12,999
    Eki Y. Baskoro
    Dec 18, 2003
  4. Huub
    Replies:
    6
    Views:
    641
  5. geletine
    Replies:
    12
    Views:
    21,793
    Fred Kleinschmidt
    May 5, 2006
Loading...

Share This Page