Hello I am a beginner in c++. I encountered this code'
namespace Parse{
class Parser{
int reg_var;
int max_var;
public Parser(int rv, int mv) : req_var(vr), max_var(mv){} // <-- not sure what this means
}
}
I am not sure if this is initializing variable in the constructor or not. Please advice. Thanks!!
Yes, it is constructing rq_var with the value vr, and max_var with the value mv, more precisly, it's calling their constructors with those paramters