📅  最后修改于: 2022-03-11 15:04:37.394000             🧑  作者: Mango
typedef enum {
NEG_INF,
ZERO,
POS_INF,
NOT_SPECIAL
} extrema;
int main(){
extrema check = POS_INF;
switch(check){
case NEG_INF: printf("neg inf"); return 1;
case ZERO: printf("zero"); return 2;
case POS_INF: printf("pos inf"); return 3;
default: printf("not special"); break;
}
return 0;
}