示例#1
0
        static void Main(string[] args)
        {
            PrintString ps1 = new PrintString(WriteToScreen);
            PrintString ps2 = new PrintString(WriteToFile);

            SendString(ps1);
            SendString(ps2);

            ReadKey();
        }
示例#2
0
 public static void SendString(PrintString ps)
 {
     ps("Hello world");
 }