DEV Community

Cover image for WRITING YOUR FIRST PROGRAM IN C# (CSHARP)
Jalalgorithm
Jalalgorithm

Posted on

WRITING YOUR FIRST PROGRAM IN C# (CSHARP)

It is always lovely to have newbies , especially one ready to try their hands on C# , as promised our introduction to C# starts today with the famous way in which every programmer kick starts their coding career , relax and follow this article carefully as you on the verge of building your first program.

**
FIRST PROGRAM?????**

Yes, that what you saw , it not an error of any sort , you will surely become a developer /programmer today and you will run your first program .
Some questions will be running on your minds as to the possibility of this.

HOW??

However before we kick start this lovely journey , I will like to chip in an analogy here , Every professional player of the football game plays on a standard pitch , a carpenter likewise works on his standard bench , also every Doctor works and operates a patient in a well equipped , state of the art theater . Likewise you especially as a C# programmer , your platform for which you perform your magic with codes and also feed command you wish the computer to implement is done through an environment called IDE .

**
WHAT IS AN IDE???**

IDE an acronym for Integrated Development Environment. It is a software application that efficiently helps programmers develop software that are both efficient and effective.

This is maybe the first problem a lot of newbies face , on the question of the right IDE to use , Let me share to you the good news , they are pretty much a lot of IDEs you could pick from and 99% of them will do the job efficiently.

In C# , they are plethora of IDEs to use ,like the Microsoft Visual Studio (community edition or professional will do ) , The Rider IDE , SlickEdit , MonoDevelop , Dev Express , However I will recommend the Visual Studio as it is the one I will use in C# tutorials here.

WRITNG YOUR FIRST PROGRAM IN C#

Like in any field , your first step is much remembered and crucial as it marks the beginning of something you’ve gained much interest in , and also ignites that excitement for the bigger ,amazing challenges and journey to come. Here today we will be compiling a program that prints hello world on the screen. Follow carefully as I walk you through the steps.

  1. Open your Visual Studio or any IDE of your choice and Locate the “FILE” tab and Select ”NEW”

Image description

  1. Click it and select “New Project”

Image description

  1. A Tab Pops up , and Just by your left lies different types of programs that can be built using Visual Studio , Click on “VISUAL C#”

Image description

  1. Then , Click on Console Application (.NET Framework) as Illustrated below

Image description

  1. Under “NAME ” type “HelloWorld” as filename

Image description

  1. Click on “OK”

Image description

  1. Wow , Welcome to the C# world , It is normal to be frightened by Some of the library bracketed below , You can ignore them for now that will be dealt with in subsequent post

Image description

  1. Between the two curly bracket beneath the Main method , kindly type Console.WriteLine(“Hello World”); , it is a syntax used to print any message on a console application.

Image description

Image description

  1. Up there is the Start button , Kinly Click it to run , or tap Ctrl + f5 key to run

  2. Now you have your Hello World on the Screen

Image description

  1. You’ve successfully Built your first program.

WHAT IS A CONSOLE APPLICATION???

This is an application with no graphical user interface , and it is certainly a good way for newbies to pick up a syntax of any language.

I Hope you learnt alot from this article , as you climb your first step to becoming that C# developer.

More articles will be rolled out to explain more concept.

You can drop reviews and questions in text box below.

©Jalalgorithm

Top comments (0)