c++ - Initializing Constant Static Array In Header File -


I just found out that the following is not valid.

  // header file class test (constant static four array [] = {'1', '2', '3'};}  

Where is the best place to start it?

Thank you in advance;

< P> The best place to be in a source file

  // header file class test {constant static four array [];}; // source file const char test :: array [] = { '1', '2', '3'};  

You can initialize the integer type in class declaration like you All other types have to be started outside the class manifesto, and only once.


Comments

Popular posts from this blog

oracle - The fastest way to check if some records in a database table? -

php - multilevel menu with multilevel array -

jQuery UI: Datepicker month format -