Classes in C#
C# classes are the primary building blocks of the language.C# also provides some predefined set of classes and methods.These classes and Methods Provides various basis functionalities that you may want to implement in your Application.Creating First "Hello World" Program
Using System;
public class Hello
{
public static void Main(string []args)
{
Console.WriteLine("Hello,World!! \n");
Console.ReadLine();
}
}
The First Line of program using System; the using keyword is used to includes the System namespace in the program.A program has multiple using statements.
The next line defines the Main methods which is the entry point for all C# programs.The Main methods states what the class does when executed.
Some C# point -
- C# is case Sensitive
- All statement and Expression must end with a semicolon(;).
- The program start execution from " Main" Method.







0 comments:
Post a Comment