using System;
public delegate void Task();
public class Starter {
public static void Main() {
Task[] tasks = { MethodA, MethodB, MethodC };
string resp;
tasks[0]();
tasks[1]();
tasks[2]();
}
public static void MethodA() {
Console.WriteLine("Doing TaskA");
}
public static void MethodB() {
Console.WriteLine("Doing TaskB");
}
public static void MethodC() {
Console.WriteLine("Doing TaskC");
}
}
|