Category: C#
Pointers in C# and Memory Safety: Span vs. C# 16 unsafe
June 3, 2026 9 minutes read For most of its life, C# has kept you away from raw memory. You get garbage collection, bounds-checked arrays, and a type system that...
Maintainability Index: A Practical Guide for C# Developers
June 1, 2026 9 minutes read If you have ever opened a code analysis report and seen a score labelled “Maintainability Index” sitting next to one of your classes, you...
Improve C# code performance with Span<T>
June 1, 2026 9 minutes read C# Span<T> and ReadOnlySpan<T>, which C# 7.2 introduced in 2017 and which .NET Core fully supports, are highly efficient structures for working with contiguous...
C# Nullable Types Explained (2026)
June 1, 2026 9 minutes read C# Nullable is two features sharing one name. The older one, nullable value types, has been around since C# 2.0 in 2005 and lets...
Anatomy of an Open-Source AI Coding Agent Built in .NET: CodeAlta
May 31, 2026 9 minutes read A large language model doesn’t perfom any action. It reads text and writes text. That is the whole contract. So how does an “AI...
An Introduction to Clean Architecture
May 25, 2026 3 minutes read Clean Architecture in C# and .NET: A Detailed Introduction It seems to me that the topic of software architecture has attracted a lot of...
C# String Interpolation Explained
May 25, 2026 9 minutes read C# string interpolation is the dollar-sign syntax that embeds variables and expressions directly inside a string literal. Introduced in C# 6, it has largely...
C# 15 Unions
May 25, 2026 9 minutes read A C# union -also called a discriminated union, tagged union or sum type- is a type whose value is exactly one of a fixed,...
C# Async/Await Explained: Complete Guide with Examples [2026]
May 22, 2026 9 minutes read Mastering C# async / await is key to building fast, scalable .NET apps. Introduced in C# 5 back in 2012, the C# async and...
Modern C# Hello World
May 21, 2026 9 minutes read The modern C# Hello World is a single line of code: [crayon-6a2111309dd11134646544/] No class, no Main() method and no using directive to write. Three...
C# Pattern Matching Explained (2026)
May 15, 2026 9 minutes read Last updated: May 2026. Covers C# 7 through C# 14. C# Pattern Matching lets you test whether an expression has a specific shape (a...
C# Record Explained
May 11, 2026 7 minutes read A C# record is a lightweight, data-centric type designed primarily for storing and representing values rather than implementing behavior. Introduced in C# 9, the...
Boxing in C#: What It Costs You and How to Get Rid of It
April 21, 2026 9 minutes read Boxing in C# is the conversion of a value type (an int, a struct, an enum, etc.) into an object reference or an interface...
LLM Chat in .NET with IChatClient: The Complete Guide
April 9, 2026 9 minutes read The IChatClient interface from the Microsoft.Extensions.AI package offers a clean, unified way to integrate LLMs like OpenAI, Copilot, or Anthropic into your application. It’s...
Visual Studio vs Visual Studio Code: The Ultimate Guide (2026)
December 30, 2025 8 minutes read Despite their similar name, Visual Studio and Visual Studio Code are two distinct products created by Microsoft. Visual Studio is a full-featured Integrated Development...
WPF vs WinForms – Making the Right Decision in 2026
December 29, 2025 8 minutes read If you’re a developer faced with the decision of selecting between Windows Presentation Foundation (WPF) and Windows Forms (WinForms) commonly referred to as WPF...
C# Array and List Fastest Loop in 2026
December 27, 2025 5 minutes read Discussions about the fastest way to loop through an array (T[]) and a List<T> in C# have been ongoing. Results can vary with each...
C# 14 Extension Members: Also Known as Extension Everything
November 12, 2025 4 minutes read C# 14 introduces extension members — also known as extension everything. The New C# 14 Extension Method Syntax The example below demonstrates how to...
Modern .NET Reflection with UnsafeAccessor
November 10, 2025 4 minutes read Reflection in .NET has traditionally been powerful but slow. Starting with .NET 8, the [UnsafeAccessor] attribute provides a zero-overhead alternative for accessing private members,...
.NET 10.0 dotnet run app.cs or file-based program
November 10, 2025 5 minutes read This post covers a new .NET 10 feature that lets you build and run a single C# file without creating a .csproj project file....
C# Optional Parameters Explained
October 27, 2025 3 minutes read In C#, optional parameters are not mandatory—they can be omitted at call site. They allow you to skip providing arguments for certain parameters. Thus...
Visual Studio Next Version: What’s Coming and What to Expect
September 1, 2025 6 minutes read In mid-August 2025, Mads Kristensen, lead designer of the C# programming language, discussed with his team The Future of Visual Studio in a YouTube...
C# ValueTuple Full Guide
July 28, 2025 9 minutes read C# 7.0 introduced ValueTuple in 2017, making it easier to work with lightweight data structures.Here’s an example using ValueTuple with the () syntax to...
Architecture of a .NET Application: 8 Case Studies
July 10, 2025 8 minutes read This recent question on Reddit’s Number of projects per solution led to interesting debates. The answer depends on the app’s size and domain. In...
Clean Architecture in ASP.NET Core
July 7, 2025 9 minutes read As applications scale, flexibility and maintainability become essential. .NET Core Clean Architecture provides a clear structure with minimal dependencies, making it a popular choice....
C# DateTime Format In A Nutshell
June 16, 2025 7 minutes read This article covers C# DateTime Format, addressing both of its main aspects: Obtain a date-formatted string. Use a pattern like "yyyy-MM-dd HH:mm:ss" to extract and...
Vertical Slice Architecture in ASP.NET Core
June 10, 2025 6 minutes read The organization of code in a solution is a subject of frequent debates. Currently, two prominent approaches have garnered attention: Clean Architecture versus Vertical...
C# Index and Range Operators Explained
May 24, 2025 3 minutes read In this post, we comprehensively demystify the C# index ^ and range .. operators. The index operator ^ Let’s start with the index ^...
Class vs Struct in C#: Making Informed Choices
May 11, 2025 9 minutes read In C# programming, choosing the right data type between classes and structs is a crucial decision that impacts application performance and design. Choosing Between Struct...
.slnx The New .NET Solution XML File Format
March 17, 2025 3 minutes read On March 13th, 2025 Microsoft officially announced the a new .NET solution file format with file extension .slnx. For example for this simple solution:...