79106372

Date: 2024-10-20 04:40:09
Score: 1
Natty:
Report link

depending on your application it can be rewritten like this

struct Parameter {
    int min;
    int max;
};

std::map <EnumType, Parameter> parametersMap {
    { FIRST_PARAMETER, { 0, 100 }},
    { SECOND_PARAMETER, { 0, 100 }},
};

int min = parametersMap[FIRST_PARAMETER].min;
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Dimitre L