C# Enum

In this lesson, you will learn about enum in C# with examples, and when to use them. C# Enum Enum or Enumeration is a set of integer constants that are used to assign name or string value. An example of is the days of the week, where the name can be ‘Days’, and the enumerators... » read more

C# Struct

In this lesson, we will explain the use of structs in C#, when to use them, and the different between structs and classes. C# Struct Structure or struct is a value type that can contains variables, functions, methods, constructors, indexers, operators, event, and properties. Structs can implement interface, however they cannot inherit from other struct... » read more

C# Visibility

In this lesson, you will learn about the different types of visibility and access modifiers in C# and how/when to use them. C# Visibility Visibility or access modifier allows us to define the way a class, method, variable, or a property is seen and accessed. Encapsulation is one of the uses of a private modifier,... » read more

C# Polymorphism

In Object oriented programming, polymorphism is a concept that allow us to defined a function in a based class and override it in the child class. Also, it allows us to have multiple function with the same name, but different implementation. 

C# Static Members

In this class, we will explain the static member, and how to use it in classes, variable, methods, and other members. C# Static Members In C#, static keyword can be used with classes, variables, properties, operators, methods, event and constructors. For classes, the static keywords will make it non-instantiable, meaning the class can’t have an... » read more

C# Interface

In this lesson, you will learn about interface in C# with example. Also, you will learn the difference between abstract class and interface. Definition of Interface Interfaces are objects in C# that looks as same as a class, but with no implementations. In other words, the interface contains a declaration or signature of methods, events,... » read more

C# Abstract Class

In this lesson, you will learn about abstract classes with example. Also, you will learn when to use abstract classes in your program.  Definition of abstract class In c#, abstract class are mostly used to define base class. As discussed previously in the inheritance lesson, we learned that a base class is to top class... » read more

C# Inheritance

In this lesson, you will learn about one of the most important concepts in object-oriented programming, which is inheritance. You will learn how to create a based class and derive class, and how implement multi inheritance and sealed class in C#. What is inheritance in C#? Inheritance is an object-oriented programming concept that allows programmers... » read more

Objects and Classes in C#

In this lesson, you will learn how to create classes and their properties, methods, events. Also, you will learn how to set up the access level for a class and its members, as well as learning other object-oriented concept, such as Encapsulation, constructors, and destructors. What is a class in C#? In object-oriented programming, a... » read more

C# Methods

In this article, you will learn about how to create a method in C# and call it. Also, you will learn about various type of passing parameter to a method, and much more. Method in C# A method (or function) is a block of code that can be declare inside a class.  Methods are useful... » read more

C# Do while loop

In this lesson, we will learn about the do while loop and its importance in C#. Examples with explanation will be provided to better understand this topic. ‘do while’ loop in C# The do-while loop is another type of loop in C#. It’s similar to the while loop, however the block of code will be... » read more

C# while Loop

In this lesson, you will learn about the “While” Loop control statement in C# and how to use it. Also, a brief explanation of nested While loop will be provided at the end of the lesson. What is the “while” Loop in C#? The “while” loop continually executes a block of code repeatedly until an... » read more

C# ‘for’ Loop

In this lesson, you will learn about the “for” loop, how to use it, and its advantage. You will also learn how to exit a loop, and the nested ‘for’ loops. What is the “For” Loop in C#? There are many situations when you need to execute a block of statements several number of times... » read more

C# switch statement

A switch statement is used to check a variable value against list of other values. The values are called cases, and can be of any datatype. Switch Statement are useful in programming when you want to make a decision based on a variable value. It’s easier than using ‘If’ statement for larger set of values... » read more

C# if statement

The ‘if’ Statement is one of the most used decision-making statement in programming. Whenever you need to test a condition; the ‘if’ statement can be used. The ‘if’ statement checks if a statement true or false and route the program based on the result of that statement. ‘if’ statement Flowchart Syntax of ‘if statement’  ... » read more