枚舉類型在C語言的定義
提問人:楊紫紅發(fā)布時間:2020-11-17
enum 枚舉名
{ 枚舉值表 };
例:enum weekday{sun, mon, tue, wed, thu, fri, sat};
enum weekday week_end, workday;
或 enum weekday{sun,mon,tue,wed,thu,fri,sat}workday;
或 enum {sun,mon,tue,wed,thu,fri,sat}week_end;
{ 枚舉值表 };
例:enum weekday{sun, mon, tue, wed, thu, fri, sat};
enum weekday week_end, workday;
或 enum weekday{sun,mon,tue,wed,thu,fri,sat}workday;
或 enum {sun,mon,tue,wed,thu,fri,sat}week_end;
繼續(xù)查找其他問題的答案?
相關(guān)視頻回答
點(diǎn)擊加載更多評論>>