Q:
                    
                
                                    Why we use keyword “const” in C#.
belongs to collection: Top 100 C# interview questions and answers 2022
Top 100 C# interview questions and answers 2022
- What is a C# programming language?
 - What are the types of comment in C# with examples?
 - What is a class in c#?
 - What is an object?
 - What is the relation between class and objects?
 - List some of the advantages of C#?
 - What are IDE’s provided by Microsoft for C# development?
 - What is the difference between a struct and a class in C#?
 - What are the similarities between a struct and a class in C#?
 - What is oops and what are the different properties provided by oops?
 - The Differences between Abstraction and Encapsulation in C#?
 - Explain sealed class in C#?
 - What are value types in C#?
 - What are reference types in C#?
 - What is the difference between value types and reference types?
 - How do you get the size of value type?
 - What are different types of the parameter in c#?
 - What is the difference between “out” and “ref” parameters in C#?
 - List out the differences between Array and ArrayList in C#?
 - Why we use keyword “const” in C#.
 - What are Access Modifiers in C#?
 - How is the exception handling done in C#?
 - Can we execute multiple catch blocks in C#?
 - What is Jagged Array in C#?
 - What is the purpose of using statement in C#?
 - How to sort an array in C#?
 - Is multiple inheritance supported in C#?
 - What is the difference between while, do while and for loop?
 - What is the difference between “constant” and “readonly” variables in C#?
 - What is the difference between dispose and finalize methods in c#?
 - What is the difference between string and StringBuilder in c#?
 - List out some of the exceptions in C#?
 - What do you mean by the delegate in C#?
 - What are the types of delegates in C#?
 - What is Nullable Type in C#?
 - What do you mean by boxing and unboxing in C#?
 - Can “this” be used within a static method?
 - Explain is an interface class?
 - Explain Abstract class?
 - What is the difference between Interface and Abstract class?
 - What is the difference between static & dynamic polymorphism?
 - What are the ways a method can be overloaded?
 - Explain ‘Virtual’ Keyword?
 - What is generics in C#.NET?
 - How do you inherit a class into other class in C#?
 - What is the difference between is and as operators in c#?
 - What are the differences between static, public and void in C#?
 - What is the difference between methods – “System.Array.Clone()” and “System.Array.CopyTo()” ?
 - Explain Partial Class in C#?
 - What are the collection types can be used in C#?
 - What is multitasking?
 - What is Multi-Threading?
 - What is a thread?
 - How can we change the priority & what the levels of priority provided by .Net?
 - How can you reference current thread of the method?
 - What is thread.sleep() in threading?
 - How can you make a thread sleep for infinite time?
 - What is suspend & Resume in Threading?
 - What is the difference between sleep & suspend?
 - How to stop the long running thread??
 - What is Thread.Join in threading?
 - What is serialization?
 - What is object pool in .Net?
 - What are circular references?
 - What is Hashtable in C#?
 - What is Constructor Overloading in C#?
 - What are indexers in C#?
 - How to implement singleton design pattern in C#?
 - Name the compiler of C#?
 - Which string method is used for concatenation of two strings in c#?
 - What is the difference between “continue” and “break” statements in C#?
 
                        
        
    
c# programming
Answer:
“Const” keyword is used for making an entity constant.
Example: const string _name = “techstudy”; Once we define a variable as a const then we can’t reassign the value of that variable(string _name).
need an explanation for this answer? contact us directly to get an explanation for this answer