C# tutorials
C# is a modern, object-oriented programming language developed by Microsoft as part of the .NET framework. Designed for simplicity, scalability, and performance, C# is widely used in building web applications, desktop software, cloud services, and enterprise solutions. Its strong typing, rich feature set, and deep integration with the .NET ecosystem make it a powerful choice for developers across industries.
E-books
C# provides a variety of advanced features, including automatic memory management through garbage collection, robust multithreading support for concurrent programming, and an extensive standard library for handling data, networking, and file operations. Its emphasis on security, reliability, and backward compatibility ensures that applications remain stable and maintainable over time.
Popular in enterprise environments, C# powers many large-scale applications, including banking, e-commerce, and healthcare systems. It is also a leading language for game development through Unity, enabling developers to create interactive and immersive experiences. With numerous frameworks like ASP.NET Core, Entity Framework, and Xamarin, along with a thriving developer community, C# continues to evolve as a versatile and efficient language for modern software development.
Language basics
Core building blocks of the language: program structure, variables, data types, operators, flow control, and type conversions.
- C# tutorial
- C# basics
- C# program structure
- C# lexical structure
- C# namespace
- C# statement
- C# variable
- C# expression
- C# operator
- C# flow control
- C# recursion
- C# foreach
- C# switch expression
- C# pattern matching
- C# data type
- C# integer types
- C# float types
- C# double
- C# Decimal
- C# BigInteger
- C# char
- C# byte
- C# enum
- C# tuple
- C# anonymous types
- C# nullable types
- C# check type
- C# Convert
- C# Type Conversions
- C# int to string Conversion
- C# string to int Conversion
- C# deconstruct
- C# collection expressions
- C# ranges and indices
- C# using
- C# yield
- C# ref, out, in
- C# params keyword
- C# exception
- C# attributes
- C# Math
- C# round
- C# Random
- C# Guid
Object-oriented programming
Classes, objects, inheritance, interfaces, records, generics, and related language features.
- C# OOP
- C# class
- C# object
- C# constructor
- C# primary constructors
- C# Property
- C# field keyword
- C# init members
- C# required modifier
- C# access modifier
- C# override modifier
- C# static
- C# readonly
- C# inheritance
- C# polymorphism
- C# abstract class
- C# interface
- C# struct
- C# record
- C# indexers
- C# operator overloading
- C# generics
- C# generic math
- C# covariance and contravariance
- C# Object.ToString
- C# object & collection initializers
- C# Shallow & Deep Copy
- C# Mapster
- C# Copy by Value vs Reference
- C# IEquatable
- C# IComparable
- C# IComparer
- C# IDisposable
Methods and functional programming
Methods, delegates, events, lambdas, expression trees, closures, and extension methods.
Strings and text
Creating, formatting, searching, and transforming strings, plus encodings, escaping, and text templating.
- C# string
- C# raw string literals
- C# String Format
- C# string interpolation
- C# StringBuilder
- C# Split string
- C# Trim string
- C# Join string
- C# Search string
- C# StringComparison
- C# Add string
- C# ToUpper
- C# Regular Expressions
- C# Encoding
- C# UTF-8 string literals
- C# escaping text
- C# CultureInfo
- C# grapheme
- C# Base64
- C# byte array to hex string
- C# Humanizer
- C# Scriban
- C# Markdown
Arrays and collections
Arrays, spans, lists, dictionaries, sets, queues, and other collection types.
- C# array
- C# ArraySegment
- C# Span
- C# ReadonlySpan
- C# collection
- C# IEnumerable
- C# List
- C# filter list
- C# List Count
- C# List Contains & Exists
- C# List Find
- C# List Add & Insert
- C# List Remove
- C# List to string
- C# List ConvertAll
- C# sort List
- C# HashSet
- C# Dictionary
- C# KeyValuePair
- C# sort Dictionary
- C# SortedDictionary
- C# Queue
- C# Stack
- C# LinkedList
- C# PriorityQueue
LINQ
Querying collections with Language Integrated Query.
Concurrency and asynchronous programming
Threads, tasks, async/await, and synchronization primitives.
Files and I/O
Reading and writing files, streams, directories, paths, and archives.
Data formats
Working with JSON, MessagePack, CSV, YAML, XML, Excel, PDF, and data frames.
Date and time
Dates, times, time spans, calendars, and time zones.
Networking and web
HTTP clients and servers, sockets, e-mail, web scraping, and browser automation.
- C# Network
- C# HttpClient
- C# GET/POST request
- C# read web page
- C# RestSharp
- C# HttpListener
- C# Server-Sent Events
- C# WebSocket
- C# Socket
- C# TcpClient
- C# TcpListener
- C# SslStream
- C# Unix domain sockets
- C# IPAddress and IPNetwork
- C# NetworkInterface
- C# ping
- C# FluentFTP
- C# send mail
- C# Mailpit
- C# parse HTML with AngleSharp
- C# Playwright
- C# Selenium
- ASP.NET Core
Databases
Accessing relational and document databases, and full-text search.
Testing, logging, and diagnostics
Unit testing, mocking, fake data, validation, logging, and performance measurement.
System and command line
Environment, processes, command line applications, and containers.
GUI and graphics
Desktop applications, 2D graphics, and plotting.
Sorting algorithms
Classic sorting algorithms implemented in C#, the built-in sorting APIs, and binary search.
System.IO API reference
Reference pages for the classes and enumerations of the System.IO namespace.
- C# BinaryReader class
- C# BinaryWriter class
- C# Directory class
- C# DirectoryInfo class
- C# DirectoryNotFoundException class
- C# DriveInfo class
- C# EndOfStreamException class
- C# File class
- C# FileAccess enum
- C# FileInfo class
- C# FileMode enum
- C# FileNotFoundException class
- C# FileOptions enum
- C# FileShare enum
- C# FileStream class
- C# FileSystemWatcher class
- C# IOException class
- C# MemoryStream class
- C# Path class
- C# PathTooLongException class
- C# StreamReader class
- C# StreamWriter class
- C# StringReader class
- C# StringWriter class
- C# TextReader class
- C# TextWriter class
last modified November 15, 2026