1.

Which among the following is added in grammar of new operator?(a) Finalize(b) Arg(c) Initializer(d) AllocatorThe question was posed to me during a job interview.This question is from New Operator topic in section Memory Allocation & Scope of Variable of Object Oriented Programming

Answer»

Right option is (c) INITIALIZER

Explanation: The new operator grammar is added with an initializer field. This can be USED to initialize an OBJECT with a user defined constructor. Hence can allocate memory as intended by the PROGRAMMER.



Discussion

No Comment Found

Related InterviewSolutions