Home » JAVA Programming » Object & Classes » Question
  1. Which of these operators is used to allocate memory for an object?
    1. alloc
    2. new
    3. give
    4. malloc
    5. None of these
Correct Option: B

Operator new dynamically allocates memory for an object and returns a reference to it. This reference is address in memory of the object allocated by new.



Your comments will be displayed only after manual approval.