Help with multi-dimentional array
    Jarrett Billingsley 
    kb3ctd2 at yahoo.com
       
    Wed Jul  9 14:37:40 PDT 2008
    
    
  
"Era Scarecrow" <rtcvb32 at yahoo.com> wrote in message 
news:g538vm$2391$1 at digitalmars.com...
>        abc = new xyz[left][right];    //error needs a const
Just a little weirdness.  When you write "new xyz[5]" it's actually sugar 
for "new xyz[](5)".  Think of it like a class -- "new Type(Params)".
For multidimensional arrays, just write
abc = new xyz[][](left, right);
It does exactly the same as the much more verbose loop. :)
    
    
More information about the Digitalmars-d-learn
mailing list