Why enum can not be used directly with printf function?

Answer Posted / sudip

main()
{
enum color{
red,black,green,yellow,blue,pink,white
};
printf("%d",green);
printf("%d",yellow);
}

this gives me output.... 23
we can use it....?/ Correct me if I am wrong...

Is This Answer Correct ?    8 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can we sort hashmap?

502


What is a class user?

556


Define a relation?

544


Which is faster hashmap or treemap?

487


Explain the most efficient method to reverse a linked list?

491






What do you mean by separate chaining?

513


Can we store null in arraylist?

467


Which interfaces are implemented by concurrentskiplistset?

485


Who invented merge sort?

480


Is hashset a collection?

464


What is array indexing?

485


What things you would care about to improve the performance of application if its identified that its db communication that needs to be improved?

529


Which sorting algorithm is the slowest?

469


Explain the Linked List

634


What do you mean by articulation point?

569