Array declaration and size initialization (C++)
===

I'm not exactly sure how to pose this question so I'll start with some example code:

    //header file
    class A
    {
    public:
        A();
    private:
        int x;
        std::string arr[x];
    }

    //cpp file

    class A
    {
    public:
        A()
        {
         /*code to get the value of x from a cmd call*/
        }
    }

Is this code valid? More specifically, can I have my string array in my header file be of size x, even though x is not specifically given a value until an A object has been created?

If this doesn't work, is my only other option to use a dynamically allocated array?