Hello please help me
I want to declare object of base class above function main or global variable( object)
and use this object in derived class like this:
class X
{
...
}
class y : public X
{
void func();
}
void y::func()
{
a[1][0] = &c; //compiler error: a[1][0] undeclared identifier
}
////////////////////////
X* arr[8][8];
void main()
{
...
}
----------------------------
how can i do this?
because when i define like this compiler error that a[1][0] undeclared identifier