I have two List, both of different lengths. What I am trying to achieve is a third List that contains the first element from list1, then the first element from list2, then s
If you don't need to keep the original lists intact, you can use a while loop to pop items off the front of each list:
while(list1.Count > 0 || list2.Count > 0)
{
if(list1.Count > 0)
{
combinedList.Add(list1[0]);
list1.RemoveAt(0);
}
if(list2.Count > 0)
{
combinedList.Add(list2[0]);
list2.RemoveAt(0);
}
}
Not quite as terse as Linq but easy to read and very clear what is going on.