(A) Main Started
(B) Main Started Hello from Test()
(C) Hello from Test() Main Started
(D) Compiler Error: Global objects are not allowed
Explanation: Output is
Hello from Test() Main Started
There is a global object ‘a’ which is constructed before the main functions starts, so the constructor for a is called first, then main()’ execution begins.
Quiz of this Question