FOR EXAMPLE : CLASS Dotnet { } creating object: Dotnet dn=new
Dotnet(); NOW THE QUESTION IS WHICH IS CALLED AS OBJECT ?
EITHER dn OR new Dotnet() and CAN YOU PROVE YOUR ANSWER?????
PLEASE REPLY...
Answers were Sorted based on User's Feedback
Answer / bakku pavan kumar
new Dotnet(); is the object,and dn is the reference to that
object.Because,
i)
you know that REFERENCE TYPES are stored in MANAGED HEAP SO
new Dotnet(); is stored in MANAGED HEAP BUT dn is stored on
STACK MEMORY AREA.
ii)
AND,until and unless we use new keyword there is no any memory
allocation.so anything that associated with new keyword is
called as an OBJECT
WHAT WILL YOU SAY???????????
PLEASE COMMENT...........
Is This Answer Correct ? | 20 Yes | 0 No |
Answer / satya
in Dotnet dn=new Dotnet(); here Dotnet dn creates a
reference variable(LHS) and new Dotnet(); creates an object.
Is This Answer Correct ? | 1 Yes | 0 No |
What are interfaces in c#?
Can abstract class have constructor?
Explain attributes in c#?
Can an exception be thrown from a catch block?
What is a decimal in c#?
What does immutable mean in c#?
What is an actual parameter?
Is string null or empty?
Can a constructor be static in c#?
What is the compiler of c#?
Is comparable a functional interface?
i am using windows authentication for c#.net remoting with iis.I uncheck the anonymous access option in directory security.when my client requests the server it returns 401:unauthorized error.How can I resolve the exception ? Please send me the reply as early as possible.