C#C
C#12mo ago
Faker

Trying to understand the basics of C# and .NET

Hello guys, sorry to disturb you all; I'm current learning C#l; I just started so I'm trying to understand some basic things first.

From what I have understood, C# is a programming language built on top of the .NET framework. C# is widely used because of its libraries/community support which help in the development of games, web services, desktop app etc... (please correct me if I'm wrong). Now when we run a C# code, our code isn't directly run/translated into machine code.

What happens, is at runtime (when we run the code), our source code is compiled into an intermediate language (in java I know we refer it to as bytecode, here what is its technical name please). This compilation is done by a virtual machine known as the CLR, common language runtime virtual machine. After compilation, this intermediate code is then translated into machine code and executed.

This make C# platform independent meaning we can run it on any OS we want.

Now I have came across 2 things, the Garbage collector and Just-In Time Compilation (JIT). I know that Garbage collector is that "free" memory (RAM) when required. But what about the JIT please; what is its use, why is it useful. I don't have a good understanding of JIT, would really appreciate if someone can explain pls.
Was this page helpful?