Tests that the specified value is zero or a positive power of two.
Namespace: SharpAssembler.CoreAssembly: SharpAssembler Core (in SharpAssembler Core.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax
C# |
---|
public static bool IsPowerOfTwo( ulong value ) |
Visual Basic |
---|
Public Shared Function IsPowerOfTwo ( _ value As ULong _ ) As Boolean |
Visual C++ |
---|
public: static bool IsPowerOfTwo( unsigned long long value ) |
Parameters
- value
- Type: System..::..UInt64
The value to test.
Return Value
trueTruetruetrue (True in Visual Basic) when the value is positive and a power of two, or zero.
Contracts
This method is pure.