<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Sahaj Kapoor</title>
    <description>The latest articles on DEV Community by Sahaj Kapoor (@skaps95).</description>
    <link>https://dev.to/skaps95</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F445607%2Fb963ef2a-7771-44aa-9e20-ea2c6b29b6e9.jpeg</url>
      <title>DEV Community: Sahaj Kapoor</title>
      <link>https://dev.to/skaps95</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/skaps95"/>
    <language>en</language>
    <item>
      <title>C# 101 - Introduction and Development Environment Setup</title>
      <dc:creator>Sahaj Kapoor</dc:creator>
      <pubDate>Mon, 03 Aug 2020 05:24:53 +0000</pubDate>
      <link>https://dev.to/skaps95/c-101-introduction-and-development-environment-setup-9gh</link>
      <guid>https://dev.to/skaps95/c-101-introduction-and-development-environment-setup-9gh</guid>
      <description>&lt;p&gt;With the current situation going around the world, people are spending a lot of time at their homes. It is the best time to pick up coding even if you have never written a line of code before in your life. &lt;/p&gt;

&lt;p&gt;I know the thought of coding seems to be very daunting at the beginning but believe me, it is easy and fun once you get the hang of it.&lt;/p&gt;

&lt;p&gt;So to get people to start coding I have started this series for &lt;strong&gt;FREE. Yes, it is 100% FREE !!!&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;There are a lot of languages to choose from like Python, Java, C, and C++, etc. There is nothing wrong with the above languages, in fact, Python is really beginner-friendly but I started my career with C# and it still has a lot of demand in the market. C# is used by a number of huge enterprises and will always be in demand as long as Microsoft exists. &lt;/p&gt;

&lt;p&gt;I have opted for C# as I have had a working experience of 3+ years in .NET and I would love to show how easy it can be to get started with it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Introduction to C# (The Theory)  
&lt;/h2&gt;

&lt;h4&gt;
  
  
  What is C#?
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;C# is an Object Oriented Programming language developed by Microsoft. &lt;/li&gt;
&lt;li&gt;It is used for developing web applications, windows applications, and mobile applications.  &lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  History of C# -
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;It was launched in 2002 with .NET Framework 1.0 &lt;/li&gt;
&lt;li&gt;There have been a lot of increments over the years and the current version of C# is 8.0 (released in 2019).&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Advantages of C# -
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;It is a modern language with simple syntax. It is very easy to learn.&lt;/li&gt;
&lt;li&gt;It has a variety of features like collections, generics, and garbage collection, etc. &lt;/li&gt;
&lt;li&gt;It supports cross-language interoperability i.e. it can communicate easily with code written in other languages. &lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Setting Up The Development Environment
&lt;/h2&gt;

&lt;p&gt;Please follow the steps mentioned below to get everything you need to start coding in C# -&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Download and install Visual Studio 2019 Community Edition from &lt;a href="https://visualstudio.microsoft.com/"&gt;Microsoft&lt;/a&gt;
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--I6pj04em--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/lce7io6ijoa2i1hcl9nq.PNG" alt="Alt Text"&gt;
&lt;/li&gt;
&lt;li&gt;Download and install .NET Core SDK from &lt;a href="https://dotnet.microsoft.com/download"&gt;.NET Site&lt;/a&gt; 
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--viuw2iSq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/i220691czw9oeq3e0u5u.PNG" alt="Alt Text"&gt;
&lt;/li&gt;
&lt;li&gt;Open Visual Studio 2019 and we can get started. &lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Our Very First Program - HELLO WORLD
&lt;/h2&gt;

&lt;p&gt;In this section, we will be building our very first console application which displays HELLO WORLD on the screen. &lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Open Visual Studio. Go to Files -&amp;gt; New -&amp;gt; Project
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--bYPcvmf2--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/1fbjeyf03q4wg6n7hoqi.PNG" alt="Alt Text"&gt;
&lt;/li&gt;
&lt;li&gt;In the type of project selection screen, select 'Console App(.NET Core)' 
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--CAZ0c9eL--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/nbiqr1kfjr060cbqxhpo.PNG" alt="Alt Text"&gt;
&lt;/li&gt;
&lt;li&gt;Now, in the 'Configure Project' screen, give the project name and desired location, and then click on next. 
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--r9AdNKzy--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/800ezh6jrak4w6hvtdvh.PNG" alt="Alt Text"&gt;
&lt;/li&gt;
&lt;li&gt;Visual Studio will not automatically generate a basic file structure and you will see a file called Program.cs
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--RFzS3Z0f--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/1ef69wfwsb5hm59i5icx.PNG" alt="Alt Text"&gt;
&lt;/li&gt;
&lt;li&gt;Content of Program.cs file should be -
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight plaintext"&gt;&lt;code&gt;using System;

namespace HelloWorldApp
{
    class Program
    {
        static void Main(string[] args)
        {
            Console.WriteLine("Hello World!");
        }
    }
}
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;p&gt;Here, the &lt;code&gt;Main()&lt;/code&gt; method is the first method that is called automatically when we run the program. &lt;br&gt;
The &lt;code&gt;Console.WriteLine()&lt;/code&gt; method is used to print whatever is inside the parenthesis to the console. Feel free to change the text from Hello world to something else if you like. &lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;To run the app we need to click on the 'run' button / green play button on the top center of the visual studio. 
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--PaYOso1c--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/rv5jovmuwexa45qnjsss.PNG" alt="Alt Text"&gt;
&lt;/li&gt;
&lt;li&gt;A black console window will pop up which displays the text written inside the &lt;code&gt;Console.WriteLine()&lt;/code&gt;
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--7ZMSo1Jl--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/i/etdjvqhvhghsa7wlymb5.PNG" alt="Alt Text"&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Congratulation!!&lt;/strong&gt; You have successfully build your first program. &lt;/p&gt;

&lt;p&gt;If you liked this tutorial please hit the like button :) &lt;br&gt;
Also, follow me as I will be posting the next tutorial very soon. Stay tuned my curious learners and thanks for reading.  &lt;/p&gt;

</description>
      <category>csharp</category>
      <category>tutorial</category>
      <category>beginners</category>
      <category>webdev</category>
    </item>
  </channel>
</rss>
