I am newbie to c++, I have not yet seen this kind of constructor, what does it do?
class A {
int x;
public:
A(int xx):x(xx) {}
};
int main() {
A a(10);
A b(5);
return 0;
}
Is the code above valid?
What does this constructor do? A(int xx):x(xx) means what? A cast?