What is the Difference between read only and constant
variables?
Answer Posted / raju
1.We can assign value to readonly field, only in
constructor or while declare the variable.But in case of
const we should assign a value while declare.
2.const=static readonly
Is This Answer Correct ? | 3 Yes | 1 No |
Post New Answer View All Answers
Is it true that all c# types derive from a common base class?
What is the C# syntax to catch any possible exception?
who is a protected class-level variable available to?
Describe a Struct ?
What is oledb in c#?
In which situation(s), the use of "Delegate" is a good idea?
list the steps in code compilation in c#?
How can you access a private method of a class?
What are some examples of desktop applications?
How does a while loop work?
How do you comment in c#?
What are the concepts of dispose method?
How many bytes is an int c#?
Can a abstract class have a constructor?
Are objects passed by reference in c#?