Hello, OnlineGDB Q&A section lets you put your programming query to fellow community users. Asking a solution for whole assignment is strictly not allowed. You may ask for help where you are stuck. Try to add as much information as possible so that fellow users can know about your problem statement easily.

need clarification

0 votes
asked Feb 15, 2018 by anonymous
enum _tag{ left=10, right, front=100, back};
printf("%d, %d, %d, %d", left, right, front, back);

1 Answer

0 votes
answered Feb 16, 2018 by anonymous
If enum constant isn't assigned value explicitly,  it will add 1 to last set enum constant and assign to current constant. Thats why right=11 and back=101.
Welcome to OnlineGDB Q&A, where you can ask questions related to programming and OnlineGDB IDE and and receive answers from other members of the community.