C# Method Declaration

In this article i am explaining about Method in C#. Method is the production block of object-oriented programming. It combines related code together and makes program easier. In C# method declaration, you can declare method by following way: Syntax: <Access Specifier> <Return Type> <Method Name>(Parameter list) {     Body } Example: public void Hello() {       Body }….

Function Parameter In C#

Parameter is the importaint part of function. However, it is optional but it makes C# function more dynamic than simple and easy function. There are two type offunction parameter in C#, Value type parameter and reference type parameter, that is discussed in lateral chapter in this section. C# parameter  just a way to passing value to….

What is class in C#

Posted in C#Tagged , ,

Class is a template, declaration or blueprint that is used for clarify object. It summarize variable members, functions, structure, properties and many more part. It is the basic building block of object oriented programming. In order to create class, the class keyword is used. Syntex class Print   {   } After creating class, you can use it by….

Classes And Methods In C#

Posted in C#Tagged , ,

In this article i am explaining about class and method in C#. A class in C# is a blueprint or template that is used for define object. However there is no need to declare object of static class. A class consist member variables, functions, properties etc. A method is a block of code in C# programming…..

Concepts Of Encapsulation And Abstraction

Encapsulation and abstraction is important part of C sharp programming that is very used for hide complex code from unauthorized users and shows only relevant information of users. What is encapsulation? Encapsulation is the way of hiding irrelevant data from the users. To understand encapsulation, consider an example of computer . Whenever you buy a computer, you….

C# Foreach Loop

Posted in C#Tagged , ,

In this article i am explaining about foreach loop in C#. foreach loop is a different type of looping constructs in C# programming that doesn’t includes initialization, termination and increment/decrement characteristics. It uses collection to take value one by one and then processes them. Syntax: foreach (string name in arr) { } Example: using System; using….

C# For Loop

Posted in C#Tagged , ,

In this article i am explaining about for loop in C#. for loop is very  powerful loop construct in C#. It is easy to use. for loop includes all three characteristics as initialization, termination and increment/decrement in a single line. using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace For_Loop_Example {     class Program     {         static….

C# Do While Loop

Posted in C#Tagged , ,

In this article i am explaining about do while loop in C#. do while loop behavior same as while loop but only one differences between them is that, do while executes at least one time. The code executes first then check for specified loop condition. But in while loop, the specified loop condition evaluated first then….

C# While Loop

To  expert programmer from novice, you need to complete knowledge the looping segments. Loop is very important thing in every programming language that saves you from repetitive nature of work. The C# supports  three loops,While, do while, and for loop. However, you can also use foreach and goto statement for looping statements. While loop is one….

Structure (C#)

In this article i am explaining about structure.Structure is the value type data type that can contain variables, methods, properties, events and etc. It simplifies the program and enhance performance of code in C# programming. The structure encapsulate small group of related variables inside a single user-defined data type. It improves speed and memory usage….