What is the difference between readonly and constant in c#

Answer Posted / karunakar

readonly value can be changed at runtime but constant never
change entire application

Is This Answer Correct ?    10 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are different types of Delegates in C#?

536


Why do we need interface in c#?

482


Why do we use dictionary in c#?

477


Why do we override in c#?

474


How can we set class to be inherited, but prevent the method from being over-ridden?

513






Why c# is called type safe language?

435


what is IEquatable

536


How to open a new form on button click in Windows forms?

507


How does return work in c#?

483


What are most desktop applications written in?

447


How do I do implement a assert?

475


What are the benefits of using generics in c#?

457


What is returned if you pass the value 12.34 to the parsefloat () function?

498


Why do we need to call CG.SupressFinalize?

530


How do destructors and garbage collection work in c#?

515