what is the purpose of new keyword while creating an object?

Answers were Sorted based on User's Feedback



what is the purpose of new keyword while creating an object?..

Answer / vasantha

new keyword is used the memory is allocated at runtime for
object

Is This Answer Correct ?    19 Yes 2 No

what is the purpose of new keyword while creating an object?..

Answer / noor mohammad

Types cannot be used without being instantiated. To
instantiate a type, you use the new operator, which invokes
the logic specified in the constructor. After completion,
the constructor returns a new instance of the specified
type—this instance can now store data as your C# program
executes.

Is This Answer Correct ?    4 Yes 1 No

what is the purpose of new keyword while creating an object?..

Answer / mahendra

creating object memory and non static variable memory with default

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C Sharp Interview Questions

What is use of abstract class in c#?

0 Answers  


What does console readline do in c#?

0 Answers  


Are structs faster than classes?

0 Answers  


Can you inherit multiple interfaces?

3 Answers  


Write code for palindrome?

10 Answers   Tech Mahindra,






Why do we write system in c#?

0 Answers  


What does clr stand for?

0 Answers  


How can you sort the elements of the array in descending order?

4 Answers  


Is it possible to have different access modifiers on the get/set methods of a property in c#?

0 Answers  


How can we Achieve Late binding in C#.Can any give one example.

5 Answers   Value Labs,


Are attributes inherited c#?

0 Answers  


What is the use of functional interface?

0 Answers  


Categories