Soenneker.Utils.Strings.HammingDistance 3.0.106

Prefix Reserved
There is a newer version of this package available.
See the version list below for details.
dotnet add package Soenneker.Utils.Strings.HammingDistance --version 3.0.106                
NuGet\Install-Package Soenneker.Utils.Strings.HammingDistance -Version 3.0.106                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Soenneker.Utils.Strings.HammingDistance" Version="3.0.106" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Soenneker.Utils.Strings.HammingDistance --version 3.0.106                
#r "nuget: Soenneker.Utils.Strings.HammingDistance, 3.0.106"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Soenneker.Utils.Strings.HammingDistance as a Cake Addin
#addin nuget:?package=Soenneker.Utils.Strings.HammingDistance&version=3.0.106

// Install Soenneker.Utils.Strings.HammingDistance as a Cake Tool
#tool nuget:?package=Soenneker.Utils.Strings.HammingDistance&version=3.0.106                

alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image

alternate text is missing from this package README image Soenneker.Utils.Strings.HammingDistance

A utility library for comparing strings via the Hamming Distance algorithm

Installation

dotnet add package Soenneker.Utils.Strings.HammingDistance

Why Hamming Distance?

Hamming Distance is a simple yet powerful metric for comparing strings or sequences of equal length. It is especially useful in scenarios where exact alignment and positional differences matter, such as:

Positional Accuracy:

Hamming Distance identifies and quantifies differences at each specific position in two sequences.

Binary or Fixed-Length Data:

It is ideal for comparing fixed-length strings, binary data, or encoded sequences.

Lightweight and Efficient:

Hamming Distance has low computational overhead, making it well-suited for performance-critical applications.

Ideal for Error Detection:

It is commonly used in error detection and correction algorithms, like detecting bit-flip errors in transmitted data.


Usage

var text1 = "kitten";
var text2 = "sitten";

double similarityPercentage = HammingDistanceStringUtil.CalculatePercentage(text1, text2); // ~83.33

Note:

Hamming Distance requires strings of equal length. If the strings differ in length, an exception will be thrown to ensure valid comparisons.

Product Compatible and additional computed target framework versions.
.NET net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net9.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
3.0.177 44 1/28/2025
3.0.176 38 1/28/2025
3.0.175 34 1/28/2025
3.0.174 39 1/28/2025
3.0.173 40 1/27/2025
3.0.172 39 1/27/2025
3.0.171 38 1/27/2025
3.0.170 44 1/26/2025
3.0.169 36 1/26/2025
3.0.168 38 1/26/2025
3.0.167 36 1/26/2025
3.0.166 30 1/25/2025
3.0.165 43 1/25/2025
3.0.164 41 1/25/2025
3.0.163 39 1/25/2025
3.0.162 29 1/25/2025
3.0.161 18 1/24/2025
3.0.160 17 1/24/2025
3.0.159 38 1/24/2025
3.0.158 34 1/24/2025
3.0.157 19 1/24/2025
3.0.156 26 1/24/2025
3.0.155 39 1/24/2025
3.0.154 40 1/24/2025
3.0.153 40 1/23/2025
3.0.152 60 1/21/2025
3.0.151 66 1/21/2025
3.0.150 62 1/21/2025
3.0.149 61 1/21/2025
3.0.148 68 1/21/2025
3.0.147 66 1/21/2025
3.0.146 64 1/21/2025
3.0.145 63 1/21/2025
3.0.144 60 1/21/2025
3.0.143 53 1/21/2025
3.0.142 65 1/20/2025
3.0.141 61 1/20/2025
3.0.140 69 1/20/2025
3.0.139 62 1/20/2025
3.0.138 63 1/20/2025
3.0.137 65 1/20/2025
3.0.136 62 1/20/2025
3.0.135 61 1/20/2025
3.0.134 65 1/19/2025
3.0.133 72 1/19/2025
3.0.132 61 1/19/2025
3.0.131 64 1/19/2025
3.0.130 61 1/19/2025
3.0.129 61 1/19/2025
3.0.128 64 1/18/2025
3.0.127 63 1/18/2025
3.0.126 65 1/17/2025
3.0.125 68 1/17/2025
3.0.124 68 1/17/2025
3.0.123 66 1/17/2025
3.0.122 69 1/16/2025
3.0.121 65 1/16/2025
3.0.120 70 1/16/2025
3.0.119 66 1/16/2025
3.0.118 67 1/16/2025
3.0.117 73 1/16/2025
3.0.116 64 1/16/2025
3.0.115 76 1/16/2025
3.0.114 73 1/15/2025
3.0.113 66 1/15/2025
3.0.112 66 1/15/2025
3.0.111 68 1/15/2025
3.0.110 50 1/15/2025
3.0.109 51 1/15/2025
3.0.108 50 1/15/2025
3.0.107 43 1/15/2025
3.0.106 33 1/14/2025
3.0.105 32 1/14/2025
3.0.104 55 1/13/2025
3.0.103 56 1/13/2025
3.0.102 60 1/13/2025
3.0.101 60 1/13/2025
3.0.100 70 1/12/2025
3.0.99 59 1/11/2025
3.0.98 64 1/11/2025
3.0.97 61 1/11/2025
3.0.96 65 1/11/2025
3.0.95 63 1/10/2025
3.0.94 49 1/10/2025
3.0.93 68 1/10/2025
3.0.92 67 1/10/2025
3.0.91 64 1/10/2025
3.0.90 106 1/3/2025
3.0.89 101 1/3/2025
3.0.88 84 1/3/2025
3.0.87 81 1/3/2025
3.0.86 83 1/2/2025
3.0.85 80 1/2/2025
3.0.84 89 1/2/2025
3.0.83 82 1/2/2025
3.0.82 98 1/1/2025
3.0.81 87 1/1/2025
3.0.80 90 1/1/2025
3.0.79 86 1/1/2025
3.0.78 99 1/1/2025
3.0.77 88 1/1/2025
3.0.76 103 12/31/2024
3.0.75 87 12/31/2024
3.0.74 99 12/31/2024
3.0.73 105 12/31/2024
3.0.72 100 12/31/2024
3.0.71 82 12/31/2024
3.0.70 77 12/31/2024
3.0.69 77 12/31/2024
3.0.68 85 12/31/2024
3.0.67 84 12/31/2024
3.0.66 80 12/30/2024
3.0.65 77 12/28/2024
3.0.64 87 12/28/2024
3.0.63 80 12/27/2024
3.0.62 80 12/27/2024
3.0.61 81 12/24/2024
3.0.60 84 12/24/2024
3.0.59 72 12/24/2024
3.0.58 82 12/24/2024
3.0.57 73 12/24/2024
3.0.56 86 12/24/2024
3.0.55 76 12/24/2024
3.0.54 84 12/24/2024
3.0.53 77 12/24/2024
3.0.52 83 12/23/2024
3.0.51 82 12/23/2024
3.0.50 87 12/23/2024
3.0.49 87 12/23/2024
3.0.48 86 12/23/2024
3.0.47 86 12/22/2024
3.0.46 84 12/22/2024
3.0.45 81 12/22/2024
3.0.44 80 12/22/2024
3.0.43 84 12/22/2024
3.0.42 86 12/21/2024
3.0.41 84 12/21/2024
3.0.40 80 12/21/2024
3.0.39 80 12/21/2024
3.0.38 78 12/21/2024
3.0.37 86 12/21/2024
3.0.36 81 12/21/2024
3.0.35 81 12/20/2024
3.0.34 84 12/20/2024
3.0.33 95 12/20/2024
3.0.32 79 12/20/2024
3.0.31 83 12/20/2024
3.0.30 87 12/19/2024
3.0.29 85 12/19/2024
3.0.28 79 12/19/2024
3.0.27 78 12/19/2024
3.0.26 89 12/18/2024
3.0.25 80 12/18/2024
3.0.24 78 12/16/2024
3.0.23 74 12/16/2024
3.0.22 80 12/10/2024
3.0.21 83 12/10/2024
3.0.20 82 12/9/2024
3.0.19 85 12/9/2024
3.0.18 87 12/9/2024
3.0.17 82 12/9/2024
3.0.16 84 12/9/2024
3.0.15 87 12/7/2024
3.0.14 90 12/6/2024
3.0.13 85 12/6/2024
3.0.12 83 12/6/2024
3.0.11 82 12/6/2024
3.0.10 89 12/6/2024
3.0.9 83 12/6/2024
3.0.8 88 12/6/2024
3.0.7 87 12/6/2024
3.0.6 90 12/6/2024
3.0.5 91 12/6/2024
3.0.4 90 12/5/2024
3.0.3 86 12/5/2024
3.0.2 85 12/4/2024
3.0.1 93 12/4/2024