1) the variable e is assigned multiple times but never used?
2) I would start like this
void Main()
{
List<Employ> emp = new List<Employ>();
emp.Add(new Employ { Name = "Ram", Contect = "5454454" });
emp.Add(new Employ { Name = "Ravi", Contect = "4578456" });
emp.Add(new Employ { Name = "Jack", Contect = "457844544" });
emp.Add(new Employ { Name = "Ram", Contect = "45784554" });
emp.Add(new Employ { Name = "Ravi", Contect = "5784545" });
emp.Add(new Employ { Name = "Jack", Contect = "4547787787" });
var employesDistinctByName = emp.GroupBy(e => e.Name).Select(y => y.First());
}
so you get rid of the double names without destroying the list. However you did not specify how to handle the combination of Name and Contect (if the name is the same, the Contect different, how to handle this)