Skip to content

ByteExtensions.Parity Method ​

Definition ​

Gets the parity of a byte, that is, whether the number of set bits is even.

c#
public static bool Parity(this Byte value);

View source

Parameters ​

NameTypeDescription
valueByteThe byte value.

Returns ​

Boolean

true if the number of set bits is even; false otherwise.