Initialization of variables in constructor

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
It's an initialisation list. There's a few handy perks to using them.

This article sums it up pretty well: http://www.cprogramming.com/tutorial/initialization-lists-c++.html
Thanks guys!!!
Topic archived. No new replies allowed.