Question: Imperative and Object-Oriented Programming Consider the following code fragment in C (not C++!): enum Dwarf {Bashful, Doc, Dopey, Grumpy, Happy, Sleepy, Sneezy}; int a1 =
Consider the following code fragment in C (not C++!): enum Dwarf {Bashful, Doc, Dopey, Grumpy, Happy, Sleepy, Sneezy}; int a1 = Dopey; What will be the value assigned to a1? 2 3 Dopey No value, an int -> Dwarf type conversion error will be generated
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
