Is there a way to find the maximum and minimum defined values of an enum in c++?
No, not in standard C++. You could do it manually:
enum Name { val0, val1, val2, num_values };
num_values will contain the number of values in the enum.
num_values