Adding custom methods for LINQ queries (C#)

Introduction

By introducing extension methods to the IEnumerableT> interface, you may expand the set of methods available for LINQ queries. Any data sequence can be converted into one single value by creating your custom aggregate method in SQL Server.

You can also build a method that returns a new series of values and acts as a custom filter or a specialized data transform for a sequence of variables.

A few examples include the Distinct and Skip techniques, as well as the Reverse.