我有一个集合:
List<Car> cars = new List<Car>();
汽车是由他们的财产唯一标识CarCode.
CarCode
我收集了三辆汽车,两辆汽车编码相同.
如何使用LINQ将此集合转换为具有唯一CarCodes的Cars?
c# linq distinct
c# ×1
distinct ×1
linq ×1