Answers for "c# generator.generate"

C#
8

c# random generator

// One string will be randomly picked and displayed 
Random rnd = new Random();
string[] secOptions = {"string one", "string two", "string three"};
int randomNumber = rnd.Next(0, 3);
string secText = secOptions[randomNumber];
Console.WriteLine(secText);
Posted by: Guest on October-28-2020

C# Answers by Framework

Browse Popular Code Answers by Language