Displaying 1 result from an estimated 1 matches for "h_category_util".
2008 Aug 07
1
string comparison
Hi,
I have a package where I do things like this a lot:
if(strncmp(CHAR(asChar(Scategory)), "chance", 6) == 0)
category = h_category_chance;
else if(strncmp(CHAR(asChar(Scategory)), "utility", 7) == 0)
category = h_category_utility;
else if(strncmp(CHAR(asChar(Scategory)), "decision", 8) == 0)
category = h_category_decision;
else if(strncmp(CHAR(asChar(Scategory)), "instance", 8) == 0)
category = h_category_instance;
else
category = h_category_error;
I would like to replace the...