I\'m struggling with this algorithm I need to write. I\'m using C#.
Say I have a List and I have a List. I need to
List
Use a cross join in LINQ:
var qry = from bag in bags from lunch in lunches select new BagLunch { Bag=bag, Lunch=lunch}; var baglunches = qry.ToList();
Edit: You'll want to modify the select clause to handle the structure of your BagLunch class.
BagLunch