You cannot execute your C# code directly into local computer. Your computer will not be able to understand high level programming language like C#. To pass proper instructions to the local computer you need a software in between C# and CPU. That software is called as a .net Framework or Core.
Not only C#, any high level language like python, ruby or PHP need this kind of software who can convert their high level code into proper instructions for CPU.
Before we go into the difference between .net Framework and .Net Core, let’s look at some important part inside .Net.
Main Parts of .Net Framework and .Net Core
.Net framework or core can be divided into two parts. CLR (Common Language Runtime) and FCL (Framework Class Library).
Let’s deep dive into both.
1] CLR (Common Language Runtime) – You can call it dot net Runtime also. It’s a Runtime provided by framework and core to run dot net supported languages like C#, F#, Visual Basic and others.
It brings your program live and also does memory management for it. It also passes further instructions to CPU (AMD or Intel).
2] FCL (Framework Class Library) – This is the second piece of dot net framework and core, called as Framework Class Library. It has different names like Base Class Library or Class Library.
But the important word here to keep in mind is Library. Class library provides code which is already written and tested by Microsoft Developers and Community (in case of .Net core).
You can use this code in your C# program to perform common activities like communication over the network using HTTP, encrypt or sign a message or to open a file on disk.
As code for these activities already written and tested, you can take advantage of it. You don’t have to spend time to write low level code which is already there.
What is the Difference Between .Net Framework and .Net Core?
- .Net Framework introduced in 2001 by Microsoft. It usually comes up as a default software with windows operating system.
- .Net Framework is not a open source software it is completely manage by Microsoft.
- .Net Framework is not a cross platform software. It doesn’t support on other operating systems except windows.
- .Net Framework was introduced by Microsoft few years ago.
- It is completely open source and manage by Microsoft and other non-Microsoft developers.
- It works across various platforms like Windows, Mac OS, Linux and even raspberry pi.
There are few others differences at technical level but above differences are the most important.
For new .net projects we would suggest you to go for .net core instead of .Net framework. You will get cross platform benefits for your application also it has been open source, so there will be lots of community help around .Net core.