Visual Basic Generating Random Letters

The sample code for generating random letters in the Visual Basic programming language is given below.

Module ModuleTest Sub Main() Dim random As Random = New Random() Dim letters As String = "abcdefghijklmnopqrstuvwxyz" Dim num As Int16 = random.Next(0, 26) Console.WriteLine(letters.Substring(num, 1)) Console.ReadLine() End Sub End Module


You May Interest

Visual Basic Adding Elements to List

Visual Basic Finding the Operating System Username

Visual Basic Get Now

Visual Basic Powering a Number

Visual Basic Randomly Shuffle a List