MCQOPTIONS
Saved Bookmarks
| 1. |
What happens when the following piece of code in file1.c, is compiled and executed? namespace { Class Temp { public: int GetVal() { return 100; } }; } //end of namespace int main() { Temp oTempObj1; Cout<<otempobj1.getval()<<endl; } </otempobj1.getval()<<endl; |
| A. | Compile Error |
| B. | 100 |
| C. | Runtime Error |
| D. | Compilation Error |
| Answer» C. Runtime Error | |