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

Tell me do array subscripts always start with zero?

498


What are the different types of data structures?

524


Is it necessary to sort a file before searching a particular item ?

547


What are the benefits of using arrays?

505


What is data structure and why we need them?

462






What are the Differences between map and hashmap?

510


Which sorting algorithm is worst?

494


Explain stacks and queues in detail.

645


How do you find the size of an arraylist?

403


What are the advantages and disadvantages of copyonwritearraylist?

625


What are the major data structures used in the rdbms?

551


Define tree edge?

509


Define primary data structures?

575


When new data are to be inserted into a data structure?

479


What is mean by abstract data type?

515