Lambda Expressions in C#
In this article, we're going to learn what Lambda Expressions in C# are in detail. Let's begin. What Are Lambda Expressions? Lambda...
MY ARTICLES:
In this article, we're going to learn what Lambda Expressions in C# are in detail. Let's begin. What Are Lambda Expressions? Lambda...
Consuming APIs over HTTP is a very common scenario when building applications. In this article, we are going to explore Refit to consume APIs in C#. ...
Performance is always an important factor in software development. It is not something only the developers of a framework must consider. When the .NET team released the Span<> struct they empowered developers to improve application performance, if used...
In this article, we are going to learn about the ternary operator (?:) in C#. Let's start. What is a Ternary Operator? Ternary Operator is...
In this article, we will learn the different methods to remove duplicates from a list in C#. List<T> is a collection having elements of the same type <T> which can contain multiple occurrences of the same item. Sometimes, we want that every element is...
In this article, we will learn about the ApiController attribute and the features it brings to our Web API controllers. Let's get...
Have you ever needed to sort a list of items but didn't want to use a built-in sorting algorithm? If so, you may have considered using the counting sort algorithm. In this article, we'll take a look at how counting sort works and how we can implement it in C#. We'll...
Often, we have transient problems in our application, such as a network failure, system rebooting, or anything else that throws an exception. In this article, we are going to learn how to implement retry logic in C# to help us handle these problems. [sc name="github"...
In this article, we are going to learn about method overloading in C#. In objected-oriented programming, method overloading is one of the important concepts to understand. It is a type of polymorphism that allows us to define methods that exist in different forms....
In this article, we are going to talk about pattern matching in C#. We'll see different patterns in action with simple examples. Let's take a look at...
In this article, we will learn the basics of regular expressions in C# and how we can use them in our C# applications. Let's...
If you're a programmer, you've probably heard of the radix sort. But what is it, exactly? And how can you use it in your code? In this article, we'll take a closer look at the radix sort in C#, learn how to implement it, and analyze its time and space complexity. [sc...
In this article, we are going to learn how to mock the file system and unit test a component that interacts with the file system. This last one is a dependency in our application's classes and we can't include it in a unit test. We are going to see that correctly...
In this article, we are going to talk about the Dictionary in C#. We will learn how to create a dictionary, add, retrieve, update, and delete elements. Among that, we will see the usage of its common properties and methods. [sc name="github"...
In this article, we are going to learn about Vertical Slice Architecture in ASP.NET Core and the benefits it provides to make our code more maintainable. We're also going to learn how it differs from traditional architecture and its advantages over the traditional...
In this article, we are going to talk about the Console class in C# and inspect the different methods and properties this class contains. The Console...
In this article, we are going to learn about Global Using Directives in C#. When we create a console application using .NET 6, the Program.cs class contains a single line of code (not counting the comment): // See https://aka.ms/new-console-template for more...
In this article, we are going to study Stack in C#, a collection of objects implementing the last-in-first-out method. Let's start. What is Stack...
In this article, we are going to demonstrate how the microservices architecture handles a long-running task execution. If you want to recap a similar task execution in a monolithic application, you can refer to this previous article. [sc name="github"...
Sorting is one of the most common programming problems that we have to solve. The good news is, that there are many sorting algorithms available to address such problems. However, each algorithm has its strengths and weaknesses, which may influence the choice of...