Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!sdd.hp.com!caen!uflorida!bikini!lius From: lius@reef.cis.ufl.edu (S. S. Liu) Newsgroups: comp.lang.c++ Subject: array size defined by a constructor Message-ID: Date: 22 Mar 91 17:57:10 GMT Sender: news@uflorida.cis.ufl.EDU Distribution: comp Organization: UF CIS Department Lines: 21 The attached C++ program will generate an error `order' undeclared, outside of functions. Is there any reason why "order" in the class scope was not recognized? Please reply by email. Thanks for your help. -- Prof. Sying-Syang Liu, lius@ufl.edu SERC, CIS Department, University of Florida, U.S.A. ------------------------------------------------------------ class mway { protected: const int order; // order of the tree int k[order]; public: mway (int ord):order(ord){} // others };