Category: C#

Difference Between String & StringBuilder Class

In this guide, we will discuss what is the difference between String and StringBuilder in C#.  String and StringBuilder in C# dotnet both are nothing more than a class.  String is immutable which means it is not liable to change whereas StringBuilder is mutable which means it is liable to change.  The namespace for C#

ToString() Method Overriding in C# with Example

In dotnet, every type directly or directly inherit from Object class.  Object class contains some methods like ToString(), GetHashCode(), Equals(), etc and all of these methods are available to all the derived classes.  As the name suggests, ToString() works fine with the built in types but in case of complex types, it does not work

What are Generics in C# with Example

In general, when we want to create a collection of items, we make use of arrays due to their strongly typed nature.  The only drawback which we experience is that they cannot grow in size.  Their size depend upon their initialization. Due to this reason, in dotnet v1.0, collections were introduced like ArrayList, Stack, Queue,

Reflection in C# with Example

In this C# reflection tutorial, you will learn what is reflection in C# and how to use it.  In dotnet, whenever you compile an application, an assembly is generated.  That assembly could be an executable file or a dll file.  As we know, all dotnet applications contains MSIL or CIL code which is converted to