Int32.IsPow2(Int32) 方法

定義

判斷值是否為兩個的乘冪。

public:
 static bool IsPow2(int value) = System::Numerics::IBinaryNumber<int>::IsPow2;
public static bool IsPow2 (int value);
static member IsPow2 : int -> bool
Public Shared Function IsPow2 (value As Integer) As Boolean

參數

value
Int32

傳回

Boolean

true 如果 value 是兩個的乘冪,則為 ,否則為 false

實作

適用於