Int16.CopySign(Int16, Int16) 方法

定義

將值的正負號複製到另一個值的正負號。

public:
 static short CopySign(short value, short sign) = System::Numerics::INumber<short>::CopySign;
public static short CopySign (short value, short sign);
static member CopySign : int16 * int16 -> int16
Public Shared Function CopySign (value As Short, sign As Short) As Short

參數

value
Int16

值,其大小用於結果中。

sign
Int16

值,其正負號用於結果中。

傳回

量級為 value 且符號為 sign 的值。

實作

適用於