namespace ConsoleApplication1 { class Program { static void Main(string[] args) { Perple p = new Perple(); p.age = 10; Pass(p); Console.WriteLine("p.age = {0}", p.age); Console.ReadKey(); } static void Pass(Perple p2) { p2 = new Perple(); p2.age = 20; } } class Perple { public int age; } }
这段程序输出后,结果会是多少呢?
博客园的朋友们,欢迎说出你们的答案哈!