yp Dictionary has donw the work
thanks bro
Dictionary<string, string> dic = new Dictionary<string, string>();
dic.Add( "t","thread1");
dic.Add( "ta","thread2");
dic.Add( "taa","thread3");
dic.Add( "tba","thread4");
dic.Add( "tbb","thread5");
dic.Add( "c","thread6");
List<string> k = dic.Keys.ToList<string>();
for(int i=0 ;i<k.Count;i++)
if (Regex.IsMatch(k[i], "ta"))
{
dic.Remove(k[i]);
Console.WriteLine(k[i]);
}
this is what i did