What is the difference between C# and C++ enumeration
This article introduces the relevant knowledge of "what is the difference between C# and C++ enumeration". In the operation of actual cases, many people will encounter such a dilemma, so let the editor lead you to learn how to deal with these situations. I hope you can read it carefully and be able to achieve something!
The difference between C++ and C# enumerations I. C++
Each element in an enumerated type can be used directly without having to go through the type. The method of the element is called
No + + operation
# include using namespace std;enum week {Monday,Thuesday}; int main () {week day; day = Monday; day = Thuesday; / / day = 4; error type conversion / / day++; error, no + + operation cout