what is use of new operator in java
Answers
Answered by
29
Q: what is use of new operator in java?
Ans: The new operator is used in Java to create new objects. It can also be used to create an array object. ... Instantiation − The 'new' keyword is used to create the object. Initialization − The 'new' keyword is followed by a call to a constructor.
Answered by
0
Answer:
The new operator is used in Java to create new objects. It can also be used to create an array object. Let us first see the steps when creating an object from a class − Declaration − A variable declaration with a variable name with an object type. Instantiation − The 'new' keyword is used to create the object.Sep 20, 2019
Please Follow Me
Similar questions