Created
May 28, 2024 15:59
-
-
Save jondjones/cae0c804a938d18bf64613d89e863fe8 to your computer and use it in GitHub Desktop.
7 New Linq Methods You Need To Know About - 6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var newProducts = new List<Product> | |
{ | |
new Product("Laptop", 999.99m) | |
}; | |
products.ExceptBy(newProducts.Select(p => p.Name), p => p.Name); | |
// "Smartphone", 699.99m) | |
// "Headphones", 199.99m) | |
// "Smartwatch", 249.99m) | |
// "Tablet", 329.99m) | |
// "Camera", 499.99m) | |
// "Printer", 149.99m) | |
// "Monitor", 179.99m) | |
// "Keyboard", 89.99m) | |
// "Headphones", 99.99m) | |
// "Mouse", 49.99m) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment