Here's an activity selection algorithmm coded in C# - probably not what you want. :) But you have not explained what you want.
static void Main(string\[\] args)
{
Random rndGen = new Random();
var activities = new List() { "bake bread", "mow lawn", "read book", "sleep", "don batman costume", "sneeze",
"have a beer", "code furiously", "make excuse for late assignment", "plead for help"};
for (int i = 0; i < 3; i++)
{
int act = rndGen.Next(activities.Count);
Console.WriteLine((i+1).ToString() + ". " + activities\[act\]);
}
Console.ReadLine();
}
Regards David R --------------------------------------------------------------- "Every program eventually becomes rococo, and then rubble." - Alan Perlis The only valid measurement of code quality: WTFs/minute.