c# - Select all keys except some key -


i know 1 key dictionary , want select other key present.

i don't want remove keyvalue pair know want select rest.

for example, have:

key:health value: 123  key:vision value: 345  key:dental value:567 

and know health there. want select other keyvalue pairs except key:health

could 1 suggest c# code implement ?

var allkeyvaluesbuthealth = dict.where(kv => kv.key != "health"); 

since deferred executed linq query it's idea materialize tolist, toarray or todictionary if want use multiple times.


Comments

Popular posts from this blog

Lists in Python -

android - can not access to progress bar in an other activity -

java - Vaadin 7 Pass Data Between Views -