The following is a legal C enumeration type enum colorType B
The following is a legal C++ enumeration type: enum colorType {BLUE, GREEN, PINK, YELLOW, RED}; True False
Solution
yes it is true
enumerated data type, in this the compiler assign integer digits starting from 0 to n to all enumerable variables one by one.
eg:
enum colorType{blue,green,pink,yellow ,red};
cout<<blue<<green<<pink<<yellow<<red; output : 0 1 2 3 4
enum day{blue,red=1,yellow,orange};
cout<<blue<<red<<yellow<<orange; output: 0 1 2 3 { 1 is already assigned it will read and will assign 2 to nxt enum variable}
enum color{blue,red=4,yelloe,pink=2,orange,blue};
cout<<blue<<red<<yellow<<pink<<orange<<blue; output: 0 4 5 2 3 4 {if the value already given it will read and start from nxt of that value.
