+ 6
Can i create object inside switch case in C++ ??
3 Answers
+ 5
Yes you can, but you should probably assign it to an object (or object pointer) of the same type that already exists outside of the switch block, unless you won't need to use it outside of the switch block.
+ 2