what is the main differnce between const,readonly and static
Answer Posted / raja
1. we can initialize constant variable only at the
declaration where as readonly varaiable can be initialized
at either declaration or in constructor.
2. we can't use static modifier for the const variable
where as readonly variable can be declared as static
Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
if we are updating a database using thread, and mean while application crashes or thread being aborted then what will happen in Database? Rollback or Database will be updated? Please explain with different scenario.
How do we achieve encapsulation in c#?
What is int tryparse in c#?
What is asp net c#?
What is .dbml file?
Is an array an object c#?
What is an escape sequence?
What is iformatprovider in c#?
Why do we use dictionary in c#?
Why we use extension methods in c#?
What is a nested type. Give an example?
How do partial classes work in c#?
What is difference between abstraction and encapsulation in c#?
What are jagged arrays used for?
What are the types of serialization?