The IsMatch method of Regex class can be used for this purpose as shown below:
string item1 = "01/01/2012";
string item2 = "01/01/2012";
string item3 = "03/06/2012";
string item4 = "03/06/2011";
string[] dates = new string[]{item1,item2,item3,item4};
string year2012=string.Empty;
string otherYears = string.Empty;
foreach (string date in dates)
{
if (Regex.IsMatch(date,@".*/\s*2012", RegexOptions.CultureInvariant))
year2012 += string.Format("{0}{1}",
string.IsNullOrEmpty(year2012)? "" : ", ",date);
else
otherYears += string.Format("{0}{1}",
string.IsNullOrEmpty(otherYears)? "" : ", ",date);
}
Console.WriteLine (year2012);
Console.WriteLine (otherYears);