C#

Join the C# Track
C# is a modern, object-oriented language with lots of great features, such as type-inference and async/await. The tooling is excellent, and there is extensive, well-written documentation.
Join the C# Track
Track mentors

25 Mentors

Our mentors are friendly, experienced C# developers who will help teach you new techniques and tricks.
Track students

6,857 Students

Join thousands of students who have enjoyed learning and improving their skills by taking this track.
Track exercises

119 Exercises

Hundreds of hours have gone into making these exercises fun, useful, and challenging to help you enjoy learning.

About C#

class HelloWorld
{
    string Hello()
    {
        return "Hello, World!";
    }
}

C# is a multi-paradigm, statically-typed programming language with object-oriented, declarative, functional, generic, lazy, integrated querying features and type inference.

Statically-typed means that identifiers have a type set at compile time--like those in Java, C++ or Haskell--instead of holding data of any type like those in Python, Ruby or JavaScript.

Object-oriented means that C# provides imperative class-based objects with features such as single inheritance, interfaces and encapsulation.

Declarative means programming what is to be done, as opposed to how it is done (a.k.a imperative programming) (which is an implementation detail which can distract from the domain or business logic).

Functional means that functions are first-class data types that can be passed as arguments to and returned from other functions.

Generic means that algorithms are written in terms of types to-be-specified-later that are then instantiated, when needed, for the specific types provided as parameters.

Lazy (a.k.a "deferred execution") means that the compiler will put off evaluating an item until required. This lets one safely do weird stuff like operating on an infinite list--the language will only create the list up to the last value needed.

Integrated Querying means the language feature called LINQ "Language-Integrated Query", which enables lazy querying directly within the language, not only its own objects but, also, external data sources through formats such as XML, JSON, SQL, NoSQL DBs and event streams.

Type inference means that the compiler will often figure out the type of an identifier by itself so you don't have to specify it. Scala and F# both do this.

Syntax is similar to that of other C-style languages such as C, C++ and Java.

.NET is the managed environment within which C# runs, so you get access to the entire .NET ecosystem, including all packages on nuget.org. .NET used to be Windows-only but, with the release of .NET Core -- as well as Mono -- you can also use C# on Mac, Linux or Unix-based systems and on mobile platforms too.

C# also has features, amongst others, to make programming with multiple threads/processors, parallelisation, asynchrony, unmanaged code in a managed environment and language interoperability easier. It is developed and maintained by Microsoft, who provides the official documentation.

Join the C# track

The c# markdown problem is my favourite

The c# markdown problem is my favourite, it is sufficiently complex to be interesting, and is similar to a lot of the code that I see. Writing good quality code from scratch is generally easier than refactoring existing bad quality code to make it good.

Relaxed. Encouraging. Supportive.

Meet the C# Track mentors

Once you join the C# language track, you will receive support and feedback from our team of mentors. Here are the bios of a few of the mentors of this track.

Avatar of Márton Garai

Márton Garai https://github.com/mrtank

I'm a professional programmer since 2012.03. Working mostly in C#. I like it Clean, and agree with Kevlin Henney in conventions.
Avatar of Aleksander Heintz

Aleksander Heintz My blog

I love programming, and do it both professionally and as a hobby. At work I do most javascript and typescript, but I've also done a lot of F# and C#.
Avatar of René Wernicke

René Wernicke https://github.com/renao

I love talking code. C# professional by day, learning new languages by night.
Avatar of Edward Rustin

Edward Rustin https://github.com/elemeno

I'm a Consultant and a Tech Lead who runs teams of developers, mostly working in C#. I've been writting C# for over a decade, building anything from trading platforms to search engines to smaller webAPIs for my own projects.
Avatar of Mariusz Bojkowski

Mariusz Bojkowski C# Today blog

I’m C# / .NET software developer and architect. My commercial adventure with software started in 2006 but it was my PASSION even before that.
Avatar of Nathan Chere

Nathan Chere NathanChere.com.au

Worked as a software developer since mid 2000's across various platforms and languages, with roughly 7 years of experience as a developer/consultant focusing primarily on .NET
Fun. Challenging. Interesting

Community-sourced C# exercises

These are a few of the 119 exercises on the C# track. You can see all the exercises here.

ETL
easy
dictionaries
lists
transforming
Raindrops
easy
filtering
strings
Minesweeper
medium
parsing
transforming
RNA Transcription
easy
strings
transforming
Bracket Push
medium
parsing
strings
Kindergarten Garden
easy
enumerations
parsing
Passionate. Knowledgeable. Creative.

Meet the C# Track maintainers

The C# Maintainers are the brains behind the C# Track. They spend their spare time creating interesting and challenging exercises that we can all learn from. We are incredibly grateful for their hard work. Here are the bios of a few of the maintainers of this track.

Avatar of Erik Schierboom

Erik Schierboom My blog

I am a developer with a passion for learning new languages. C# is a well-designed and expressive language that I love programming in.
Avatar of Rob Keim

Rob Keim

I stumbled upon this site when I was trying to learn about functional programming and F#. Little did I know, I'd wind up becoming a contributor and learning a whole lot more than what I originally intended to. I had never contributed to an open source project before, and it's been a very rewarding experience.
Avatar of John Reese

John Reese I sometimes write about stuff

I am a software engineer with a passion for testing and C#. If you have any questions about the C# track or the language in general, feel free to ask; I'd love to hear them.

Get started with the C# track. As with everything on Exercism, it's 100% free!

Join the C# Track