<!--
{
  "documentType" : "article",
  "framework" : "Swift",
  "identifier" : "/documentation/Swift/UInt32/BinaryInteger-Implementations",
  "metadataVersion" : "0.1.0",
  "role" : "collectionGroup",
  "title" : "BinaryInteger Implementations"
}
-->

# BinaryInteger Implementations

## Topics

### Operators

[`static func != <Other>(Self, Other) -> Bool`](/documentation/Swift/UInt32/!=(_:_:)-6i9jj)

Returns a Boolean value indicating whether the two given values are not
equal.

[`static func & (UInt32, UInt32) -> UInt32`](/documentation/Swift/UInt32/&(_:_:))

Returns the result of performing a bitwise AND operation on the two given
values.

[`static func & (Self, Self) -> Self`](/documentation/Swift/UInt32/&(_:_:)-3g9c6)

Returns the result of performing a bitwise AND operation on the two given
values.

[`static func * (UInt32, UInt32) -> UInt32`](/documentation/Swift/UInt32/*(_:_:))

Multiplies two values and produces their product.

[`static func + (UInt32, UInt32) -> UInt32`](/documentation/Swift/UInt32/+(_:_:))

Adds two values and produces their sum.

[`static func - (UInt32, UInt32) -> UInt32`](/documentation/Swift/UInt32/-(_:_:))

Subtracts one value from another and produces their difference.

[`static func == <Other>(Self, Other) -> Bool`](/documentation/Swift/UInt32/==(_:_:)-6gtla)

Returns a Boolean value indicating whether the two given values are
equal.

[`static func | (Self, Self) -> Self`](/documentation/Swift/UInt32/_(_:_:)-1zok6)

Returns the result of performing a bitwise OR operation on the two given
values.

[`static func ^ (Self, Self) -> Self`](/documentation/Swift/UInt32/_(_:_:)-21za9)

Returns the result of performing a bitwise XOR operation on the two given
values.

[`static func / (UInt32, UInt32) -> UInt32`](/documentation/Swift/UInt32/_(_:_:)-544gh)

Returns the quotient of dividing the first value by the second.

[`static func | (UInt32, UInt32) -> UInt32`](/documentation/Swift/UInt32/_(_:_:)-5p6yw)

Returns the result of performing a bitwise OR operation on the two given
values.

[`static func > (Self, Self) -> Bool`](/documentation/Swift/UInt32/_(_:_:)-60hif)

[`static func % (UInt32, UInt32) -> UInt32`](/documentation/Swift/UInt32/_(_:_:)-6ovdh)

Returns the remainder of dividing the first value by the second.

[`static func < <Other>(Self, Other) -> Bool`](/documentation/Swift/UInt32/_(_:_:)-7gl7s)

Returns a Boolean value indicating whether the value of the first
argument is less than that of the second argument.

[`static func ^ (UInt32, UInt32) -> UInt32`](/documentation/Swift/UInt32/_(_:_:)-9mox3)

Returns the result of performing a bitwise XOR operation on the two given
values.

[`static func > <Other>(Self, Other) -> Bool`](/documentation/Swift/UInt32/_(_:_:)-ru4w)

Returns a Boolean value indicating whether the value of the first
argument is greater than that of the second argument.

[`static func <= (Self, Self) -> Bool`](/documentation/Swift/UInt32/_=(_:_:)-4zprc)

[`static func >= <Other>(Self, Other) -> Bool`](/documentation/Swift/UInt32/_=(_:_:)-6655v)

Returns a Boolean value indicating whether the value of the first
argument is greater than or equal to that of the second argument.

[`static func >= (Self, Self) -> Bool`](/documentation/Swift/UInt32/_=(_:_:)-69qui)

[`static func <= <Other>(Self, Other) -> Bool`](/documentation/Swift/UInt32/_=(_:_:)-vr4i)

Returns a Boolean value indicating whether the value of the first
argument is less than or equal to that of the second argument.

[`static func >> <Other>(Self, Other) -> Self`](/documentation/Swift/UInt32/__(_:_:)-2fuku)

Returns the result of shifting a value’s binary representation the
specified number of digits to the right.

[`static func << <Other>(Self, Other) -> Self`](/documentation/Swift/UInt32/__(_:_:)-63byq)

Returns the result of shifting a value’s binary representation the
specified number of digits to the left.

[`static func >> <RHS>(Self, RHS) -> Self`](/documentation/Swift/UInt32/__(_:_:)-8299k)

Returns the result of shifting a value’s binary representation the
specified number of digits to the right.

[`static func << <RHS>(Self, RHS) -> Self`](/documentation/Swift/UInt32/__(_:_:)-8ecom)

Returns the result of shifting a value’s binary representation the
specified number of digits to the left.

[`static func >>= <Other>(inout Self, Other)`](/documentation/Swift/UInt32/__=(_:_:)-2nln1)

Stores the result of shifting a value’s binary representation the
specified number of digits to the right in the left-hand-side variable.

[`static func <<= <Other>(inout Self, Other)`](/documentation/Swift/UInt32/__=(_:_:)-9xth9)

Stores the result of shifting a value’s binary representation the
specified number of digits to the left in the left-hand-side variable.

[`static func ~ (Self) -> Self`](/documentation/Swift/UInt32/~(_:))

Returns the inverse of the bits set in the argument.

### Initializers

[`init()`](/documentation/Swift/UInt32/init())

Creates a new value equal to zero.

[`init<Other>(clamping: Other)`](/documentation/Swift/UInt32/init(clamping:))

Creates a new instance with the representable value that’s closest to the
given integer.

[`init<T>(truncatingIfNeeded: T)`](/documentation/Swift/UInt32/init(truncatingIfNeeded:))

Creates a new instance from the bit pattern of the given instance by
sign-extending or truncating to fit this type.

### Instance Properties

[`var bitWidth: Int`](/documentation/Swift/UInt32/bitWidth-swift.property)

The number of bits in the current binary representation of this value.

[`var description: String`](/documentation/Swift/UInt32/description)

A textual representation of this value.

### Instance Methods

[`func advanced(by: Int) -> Self`](/documentation/Swift/UInt32/advanced(by:))

Returns a value that is offset the specified distance from this value.

[`func distance(to: Self) -> Int`](/documentation/Swift/UInt32/distance(to:))

Returns the distance from this value to the given value, expressed as a
stride.

[`func isMultiple(of: Self) -> Bool`](/documentation/Swift/UInt32/isMultiple(of:))

Returns `true` if this value is a multiple of the given value, and `false`
otherwise.

[`func quotientAndRemainder(dividingBy: Self) -> (quotient: Self, remainder: Self)`](/documentation/Swift/UInt32/quotientAndRemainder(dividingBy:))

Returns the quotient and remainder of this value divided by the given
value.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)