Click here to Skip to main content
15,851,319 members
Articles / General Programming / Performance

Using Span<T> to Improve Performance of C# Code

Rate me:
Please Sign up or sign in to vote.
4.78/5 (38 votes)
27 Nov 2021CPOL7 min read 77.8K   55  
Overview of Span C# feature and an example of how it can improve the existing codebase
Span is a relatively new C# feature that allows us to reduce memory allocation almost with no developer effort. In this article, we'll have a look at it and how we can use it.


Daily Counts


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Written By
Team Leader
Ukraine Ukraine
Team leader with 8 years of experience in the industry. Applying interest to a various range of topics such as .NET, Go, Typescript and software architecture.

Comments and Discussions