MathF.CopySign(Single, Single) Method

Definition

Returns a value with the magnitude of x and the sign of y.

public static float CopySign (float x, float y);

Parameters

x
Single

A number whose magnitude is used in the result.

y
Single

A number whose sign is the used in the result.

Returns

A value with the magnitude of x and the sign of y.

Applies to

제품 버전
.NET Core 3.0, Core 3.1, 5, 6, 7, 8, 9