What is the equivalent for this in VB.net
int? x; int s; s = x ?? 5;
if() operator is the null coalescing operator in vb.
s = If(x, 5)
There are three ways in vb.net for nullable declaration
Dim x? As Integer Dim x As Integer? Dim x As Nullable(Of Integer) Dim s As Integer s = If(x, 5)