4 ms·
If you are not restricted to C++98 or older, you could pass a lambda to getDimensionSum() and spare you having to use method pointers.
by au750 7y ago
If you are not restricted to C++98 or older, you could pass a lambda to getDimensionSum() and spare you having to use method pointers.