Skip to content

Instantly share code, notes, and snippets.

@AnthonyDGreen
Created February 5, 2019 22:45
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save AnthonyDGreen/1a4e767218a11f4bdde17cac0812a7a6 to your computer and use it in GitHub Desktop.
Module Program
Sub Main()
Dim i As Integer? = If(False, 1, Nothing)
Console.WriteLine(i)
Dim operation As Func(Of Integer, Integer, Integer) =
If(True,
AddressOf Add,
AddressOf Subtract)
End Sub
Function Add(left As Integer, right As Integer) As Integer
Return left + right
End Function
Function Subtract(left As Integer, right As Integer) As Integer
Return left - right
End Function
End Module
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment