4 // This is a lambda test for situation when parent is infering return types and child not
10 public decimal UnitPrice;
15 public static void Main ()
17 Product[] products = new[] {
18 new Product { CategoryID = 1, UnitPrice = 1m }
21 var categories = from p in products
22 group p by p.CategoryID into g
25 ExpensiveProducts = from p2 in g
26 where (p2.UnitPrice > g.Average (p3 => p3.UnitPrice))