IntegerMath.IsEven Method

Definition

Namespace: Extreme.Mathematics
Assembly: Extreme.Numerics (in Extreme.Numerics.dll) Version: 8.1.23

Overload List

IsEven(BigInteger) Returns a value indicating whether an integer is even.
IsEven(Decimal) Returns a value indicating whether an integer is even.
IsEven(Int16) Returns a value indicating whether an integer is even.
IsEven(Int32) Returns a value indicating whether an integer is even.
IsEven(Int64) Returns a value indicating whether an integer is even.

IsEven(BigInteger)

Returns a value indicating whether an integer is even.
C#
public static bool IsEven(
	BigInteger n
)

Parameters

n  BigInteger
A BigInteger number.

Return Value

Boolean
true if the number is even; false otherwise.

IsEven(Decimal)

Returns a value indicating whether an integer is even.
C#
public static bool IsEven(
	this decimal n
)

Parameters

n  Decimal
A Decimal number.

Return Value

Boolean
true if the number is even; false otherwise.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Decimal. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

IsEven(Int16)

Returns a value indicating whether an integer is even.
C#
public static bool IsEven(
	this short n
)

Parameters

n  Int16
A 16-bit integer.

Return Value

Boolean
true if the number is even; false otherwise.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Int16. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

IsEven(Int32)

Returns a value indicating whether an integer is even.
C#
public static bool IsEven(
	this int n
)

Parameters

n  Int32
A 32-bit integer.

Return Value

Boolean
true if the number is even; false otherwise.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Int32. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

IsEven(Int64)

Returns a value indicating whether an integer is even.
C#
public static bool IsEven(
	this long n
)

Parameters

n  Int64
A 64-bit integer.

Return Value

Boolean
true if the number is even; false otherwise.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Int64. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

See Also