Usually when you have a constant private member variable in your class, which only has a getter but no setter, it would look something like this:
// Example.h
cl
First, the variable is defined in the class definition, not in the constructor. It's initialized in the constructor.
Second, the way to do that is just like what your constructor currently does: store the value in it from the initializer list:
Example::Example(std::vector myVec)
: m_value(myVec.size() ? myVec.size() + 1 : -1) {
}