Skip to content

ByteExtensions.DidSubtractionHalfBorrow Method ​

Definition ​

Determines whether a subtraction produced a half borrow, that is, a borrow from bit 4 to bit 3.

c#
public static bool DidSubtractionHalfBorrow(this Byte difference, Byte left, Byte right);

View source

Parameters ​

NameTypeDescription
differenceByteThe result of the subtraction.
leftByteThe left operand.
rightByteThe right operand.

Returns ​

Boolean

true if the subtraction produced a half borrow; false otherwise.