fbpx

Latest Posts On Code Maze

Sort List by Property in the Object in .NET

Sort List by Property in the Object in .NET

In this article, we are going to look at different ways to sort a List by a property in the object. Let's dive in. Creating a Demo Model Let's begin by creating...

Timer in C#

Timer in C#

In this article, we are going to learn how to use Timer in C#. We can set a timer to generate events following a previously set interval. In addition, the Timer class does this without blocking our program's main execution thread. To download the...

LINQ Basic Concepts in C#

LINQ Basic Concepts in C#

In this article, we are going to learn about LINQ (Language Integrated Query) in C#. We are going to see why we should use LINQ in our codebase, and different ways to implement and execute LINQ queries. Furthermore, we will explore some of the frequently used LINQ...

How to Convert String to Title Case in C#

How to Convert String to Title Case in C#

In this article, we are going to learn how to convert string to title case in C#. In the title case, the first character of a word is the uppercase letter, while the remaining characters are in lowercase. To download the source code for this...

Code Maze Weekly #117

Code Maze Weekly #117

Issue #117 of the Code Maze weekly. Check out what's new this week and enjoy the read. .NET and C# Search videos through the YouTube Data API from C# [blog.elmah.io] If you need to implement YouTube search results on a website, this article by Thomas Ardal is just for...

Quicksort Algorithm in C#

Quicksort Algorithm in C#

Quicksort is one of the most efficient algorithms that we can use to accomplish our sorting goals. In this article, we discuss how to implement Quicksort in C# as well as analyze its time and space complexity. To download the source code for this...

Serialization and Deserialization in C#

Serialization and Deserialization in C#

In this article, we’re going to explore the different flavors of serialization and deserialization in C#. Let’s dive into it. What Is Serialization and...

StringBuilder in C#

StringBuilder in C#

In this article, we are going to talk about StringBuilder in C#. Let's dive in. What is StringBuilder in C#? The string type is immutable in C#, so we cannot...

Compare Arrays in C#

Compare Arrays in C#

There are many different ways to compare arrays in C#. In this article, we are going to cover many of them, check some differences between each approach, and inspect a benchmark result for the fastest technique. To download the source code for this...

Optional Parameters in ASP.NET Core Web API Routing

Optional Parameters in ASP.NET Core Web API Routing

In this article, we are going to look at how to use optional parameters in ASP.NET Core Web API routing. Additionally, we are going to learn how to use optional parameters with route constraints. To download the source code for this article, you can...

Code Maze Weekly #116

Code Maze Weekly #116

Issue #116 of the Code Maze weekly. Check out what's new this week and enjoy the read. .NET and C# Performance benefits of sealed class in .NET [www.meziantou.net] Gérald Barré gives us a nice insight into the performance benefits of using sealed classes. Real-World...

In-Memory Caching in ASP.NET Core

In-Memory Caching in ASP.NET Core

In this article, we are going to talk about the caching basics and how to implement In-Memory Caching in ASP.NET Core applications. Let's start. What is Caching?...

How to Write a JSON Into a File in C#

How to Write a JSON Into a File in C#

In this post, we are going to learn how to write a JSON into a file in C#. JSON is structured, lightweight, widely supported, more readable, and more efficient...

Remove Time From a DateTime Object in C#

Remove Time From a DateTime Object in C#

When we need to work with time in C# we use the DateTime type. DateTime values have two components, as easily inferred from the name - a date part and a time part. Since in some cases we might need only one part out of the two, in this article we're going to learn how...

Health Checks in ASP.NET Core

Health Checks in ASP.NET Core

In this article, we are going to look into Health Checks in ASP.NET Core. Then we are going to look into the Health Checks Middleware provided by ASP.NET Core to create some checks and add a nice dashboard to view all our Health Checks. Finally, we will briefly look...

How to Sum Up Elements of an Array in C#

How to Sum Up Elements of an Array in C#

A frequent question in .NET interviews is about operations using arrays. In this article, we are going to learn how to sum up elements of an array in C#. After studying the different techniques, we are going to build a performance benchmark and check which one is the...

Using Variables Inside Strings in C#

Using Variables Inside Strings in C#

In this article, we are going to explore how to use variables inside strings in C#. There are a few ways to accomplish that, depending on the C# version being used. To download the source code for this article, you can visit our GitHub...

Merge Sort in C#

Merge Sort in C#

Merge sort in C# is one of the algorithms that we can use to sort elements. Merge Sort is known to be efficient as it uses the "divide and conquer" strategy that we are going to discuss as we implement it. To download the source code for this...

Code Maze Weekly #115

Code Maze Weekly #115

Issue #115 of the Code Maze weekly. Check out what's new this week and enjoy the read. .NET and C# How to send ASP.NET Core Identity emails with Twilio SendGrid [swimburger.net] ASP.NET Core provides mechanisms to confirm emails and reset passwords, but it's up to us...