Relation operator: less, bigger
Imports System
Public Class MainClass
Shared Sub Main()
Dim intNumber As Integer
intNumber = 20
'Is intNumber less than or equal to 27?
If intNumber <= 27 Then
System.Console.WriteLine("Is 'intNumber' less than or equal to 27? Yes!")
Else
System.Console.WriteLine("Is 'intNumber' less than or equal to 27? No!")
End If
'Is intNumber greater than 27?
If intNumber > 27 Then
System.Console.WriteLine("Is 'intNumber' greater than 27? Yes!")
Else
System.Console.WriteLine("Is 'intNumber' greater than 27? No!")
End If
'Is intNumber greater than or equal to 27?
If intNumber >= 27 Then
System.Console.WriteLine("Is 'intNumber' greater than or equal to 27? Yes!")
Else
System.Console.WriteLine("Is 'intNumber' greater than or equal to 27? No!")
End If
End Sub
End Class
Related examples in the same category