C# Single GreaterThanOrEqual
Description
Single GreaterThanOrEqual
returns a value that indicates
whether a specified Single value is greater than or equal to another specified
Single value.
Syntax
Single.GreaterThanOrEqual
has the following syntax.
public static bool operator >=(
float left,
float right
)
Parameters
Single.GreaterThanOrEqual
has the following parameters.
left
- The first value to compare.right
- The second value to compare.
Returns
Single.GreaterThanOrEqual
method returns true if left is greater than or equal to right; otherwise, false.
Example
The GreaterThanOrEqual method defines the operation of the greater-than-or-equal operator for Single values.
using System;//from w w w . java 2s . c om
public class MainClass{
public static void Main(String[] argv){
float f1 = 1.2F;
float f2 = 1.2F;
Console.WriteLine(f1 >= f2);
}
}
The code above generates the following result.