Code Maze Weekly #134
Issue #134 of the Code Maze weekly. Check out what's new this week and enjoy the read. .NET and C# Top Picks Fun With Custom Interpolated String Handlers [khalidabuhakmeh.com] We can all agree that string interpolation was an excellent addition to C#. But did you know...
Heap Sort in C#
In this article, we'll look at the heap sort algorithm in C#. We'll discuss what the algorithm is, how it works, and see some code examples that demonstrate how to implement it. Finally, we'll discuss its time and space complexity and compare the algorithm to other...
Flags Attribute For Enum in C#
In this article, we are going to learn about the Flags attribute for enum in C#, what its benefits are, and how to use it in a practical example. Need to send a lot of emails at once? Here's one way to do it Niels Swimberghe. Just make...
Type Checking and Type Casting in C#
In this article, we are going to learn various ways of converting a value from one type to another (type casting) and how to check the type of a value at run time (type checking). IOptions is a useful interface that enables us to pass on configuration values more...
Running .NET Core Applications as a Linux Service
In this article, we are going to learn how to run a .NET application as a Linux service. So let's get started. .NET Support for Linux Service Linux...
How to Implement Lucene.NET
In this article, we are going to be learning how to implement Lucene.NET in C#. We will cover the entire process from installing the library, to indexing and searching. .NET 7 Preview 6 has introduced a new caching middleware. Let's see how it works in this...
How to Convert String Array to String in C#
In this article, we are going to learn how to convert a string array to a string in C#. We will cover five different approaches to achieve the same result, and in the end, we will inspect benchmark results to see the fastest way to accomplish the conversion. ASP.NET Core Web API comes out with some powerful inbuilt features....
Covariance and Contravariance in C#
In this article, we’re going to learn why covariance and contravariance are important, what they are, and how to use them in various scenarios using a few examples. [sc name="github"...
How to Turn a C# Object Into a JSON String in .NET?
In this article, we're going to learn how to serialize a C# object into a JSON string using the two main JSON libraries in the .NET ecosystem. Also, we're going to learn how to control different aspects of the serialization process. [sc name="patreon-source-code"...