Enum statement differ from a typedef statement, Computer Engineering

Assignment Help:

How does an enumstatement differ from a typedef statement?

Typedef statement permits user to define an identifier that would show an exiting data type. The user-defined data type identifier can be used further to declare variables. It has the following syntax

                                     Typedef   datatype identifier;

Where data type refers to exiting data type and identifier is the new name given to this data type. For example

                                     Typedef int nos;

nos here symbolizes int type and now it can be used later to declare variables like

                                   nos num1,num2,num3;

Enum statement is used to declare variables that can have one of the values enclosed within braces called as enumeration constant. After declaring this, we can declare variables to be of this 'new' type. It has the following syntax

   enum identifier {value1, value2, value3......,valuen);

 


Related Discussions:- Enum statement differ from a typedef statement

Illustrate control and timing signals, Q. Illustrate control and timing sig...

Q. Illustrate control and timing signals? The requirement of I/O from different I/O devices by processor is quite unpredictable. In fact it relies on I/O needs of particular pr

Backward chaining, Backward Chaining: In generally given that we are o...

Backward Chaining: In generally given that we are only interested in constructing the path whether we can set our initial state to be the theorem statement and search backward

What are escape sequences characters, What are escape sequences characters?...

What are escape sequences characters? List any six of them.  The characters which when used with output functions like printf( ),putc(),put() etc. helps in formatting the outpu

Domains of artificial intelligence, The major domains of AI research and...

The major domains of AI research and development. AI applications can be grouped under three major areas cognitive science robotics and natural interfaces though these class

What are the ways to truncate guard bits, What are the ways to truncate gua...

What are the ways to truncate guard bits? 1. Chopping 2. Von Neumann rounding 3. Rounding procedure.

The periodic table of elements, Make a data structure to store information ...

Make a data structure to store information about the elements in the periodic table of elements.  For each element, store the name, atomic number, chemical symbol, class, atomic we

What is a disk drive, What is a disk drive? The electro mechanical mech...

What is a disk drive? The electro mechanical mechanism that spins the disk and moves the read/write heads known as disk drive.

Explain priority interrupt, What is priority interrupt? A priority inte...

What is priority interrupt? A priority interrupt is an interrupt that establishes a priority over the various sources to verify which condition is to be serviced first when two

Nmknl''knl, Ask question bhjjnjnnjnjm#Minimum 100 words accepted#

Ask question bhjjnjnnjnjm#Minimum 100 words accepted#

Explain about micro-instruction formats, Q. Explain about Micro-instruction...

Q. Explain about Micro-instruction Formats? Now let's focus on format of a micro-instruction. The two widely used formats employed for micro-instructions are vertical and horiz

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd