// Collection of code snippets by Arne Vajhøj // (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) using System; using System.Linq; namespace E { public class P { public virtual string[] V { get { return new string[] { "field1"}; } } } public class C : P { public override string[] V { get { return base.V.Concat(new string[] { "field2"}).ToArray(); } } } public class Program { public static void Main(string[] args) { P o = new C(); foreach(string s in o.V) { Console.WriteLine(s); } } } }