.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month

Home >> Code Snippets >> Collections >> Post New Resource Bookmark and Share   

 Subscribe to Code Snippets

C# - Beginners - Lets Begin with Main

Posted By:Sadhuryan       Posted Date: January 05, 2011    Points: 15    Category: Collections    URL: http://www.dotnetspark.com  

This is a simple C# program for beginners. Lets start with Main()

using System;

namespace BeginnersTutorial
  public static class Program
    //A program to simply print text
    public static void Main()
      //Writes the specified data, followed by the current line terminator, to the standard output stream.
      Console.WriteLine("Hi User!");
      Console.WriteLine("A Simple C# program to display a string.");

      //Obtains the next character or function key pressed by the user. The pressed key is displayed in the console window.


Further Readings:


No response found. Be the first to respond this post

Post Comment

You must Sign In To post reply
Find More code samples in C#, ASP.Net, Vb.Net and more Here

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend