what is the purpose of new keyword while creating an object?
Answer Posted / 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 |
Post New Answer View All Answers
How do you pronounce c#?
What is autopostback in c#?
What are mutable and immutable types in c#?
How do I port "synchronized" functions from visual j++ to c#?
Explain the use of SN.exe
How do I create a single-file assembly?
Please explain value types and reference types used in c#?
What is typeof c#?
Between windows authentication and sql server authentication, which one is trusted and which one is untrusted?
what is generics? can u explain 5 to 6 examples on generics that covers class,method,structure,list,delegates?
What are the Features in .net framework 1.1
How long will it take to learn c#?
What is a byte in c#?
Explain deadlock?
Why we use anonymous methods in c#?