The below program will do so
class MainClass
{
public static void Main(string[] args)
{
var evenNumList = new List<int>();
var oddNumList = new List<int>();
GetEvenOddNumbersUsingOutParameters(out evenNumList, out oddNumList);
}
private static void GetEvenOddNumbersUsingOutParameters(out List<int> evenNumList,
out List<int> oddNumList)
{
var numbers = Enumerable.Range(1, 20); //generate numbers between 1 to 20
evenNumList = numbers.Where(i => i % 2 == 0).ToList();
oddNumList = numbers.Where(i => i % 2 != 0).ToList();
}
}