Is this code correct?

From: highli (highli_at_cls.com)
Date: 07/30/04


Date: Fri, 30 Jul 2004 15:13:30 GMT


   Array2D = new (int*)[M];

   for(int i = 0; i < M; ++i)
      Array2D[i] = new int[N];

   for(int i = 0; i < M; ++i)
      delete [] Array2D[n];

   delete [] Array2D;

What is meaning of "(int*)[M]"?

Is it necessary to "delete [] Array2D;", or just "delete Array2D;"?

Thanks in advance!