Why can't I declare a dynamic array (vector) inside a C++ class ? In the following snippet, the static array 's' seems to work fine but vector 't' creates error during compilation . (I compiled using GNU G++ compiler).
1 2 3 4 5 6 7 8 9 10 11
class node
{
int s[5]; // Seems to work fine
vector<int> t(5); // Creates error
}