Im trying to create a class that will return some random numbers. Now i know how to create a bunch of random numbers and put them in a listbox using :
Random RndNmbrs = new Random();
int n = RndNmbrs.Next();
for (int a = 0; a < 10; a++)
{
lstBubbleUnorderd.Items.Add(RndNmbrs.Next(0, 10));
}
But I want to put that code in a class and call it from Program.cs
,
I have tried several things but I cant get it to work so please tell me how one is supposed to do this ?