Imports System.Text.RegularExpressions Imports System Public Class MainClass Shared Sub Main() If Not Regex.Match("City", "^([a-zA-Z]+|[a-zA-Z]" & _ "+\s[a-zA-Z]+)$").Success Then ' city was incorrect Console.WriteLine("Invalid City") End If End Sub ' Main End Class