What is difference between value and reference types ?
Answer Posted / thirupathi reddy
value refers what is present in the address of the memory
Reference type refers to the address of the memory
Ex:
int a = 10( here the value stores in the address 'a' and the value of that address is 10)
int b = &a (here the variable b refers the address of
the variable a)
here if we print("%d",a) the value prints
here if we print("%d",b) the reference value of a is printed.
this is the difference between "value" and "reference values"
| Is This Answer Correct ? | 0 Yes | 2 No |
Post New Answer View All Answers
Explain About delegates
Suppose two interfaces have same method, so how will you implement these methods in derive class?
Is list a collection c#?
What are the basics of c#?
Can I fly with a loop recorder?
Explain streamreader/streamwriter class?
What is xor operation?
Show us in simple steps to create setup & deployment project for windows application?
what optimizations does the c# compiler perform when you use the /optimize+ compiler option?
What is difference between list and ilist in c#?
What is strong name assembly?
What is the difference between inheritance and abstract class?
What are concrete classes?
What is difference between Trace and Debug
What are the access modifiers in c#?