Example of Console Application In C#

In this article, I will show the example of Console Application in C#.
  • 8755

Introduction

A console application is the simplest form of C# program. Console programs are very easy to develop. Console programs read input and write output. A console application runs in a console window same as C++ program.

Example

using System;

using System.Collections.Generic;

using System.Linq;

using System.Text;

namespace ConsoleApplication11

{

    class Program

    {

        static void Main(string[] args)

        { 

          // Write to console window.

       Console.WriteLine("----------------Thanks for Reading DotNet Heaven Articles---------------");

    Console.ReadLine();

        }

    }

}
 

The output of following program


Clipboard208.jpg

© 2019 DotNetHeaven. All rights reserved.