Suppose that I am having a dictionary as the following.
new_vocd = {'amazon': [668], 'flipkart': [34,56], 'myntra': [78,89,98], 'ebay': [876,768], 'microsoft': [67]}
I am having a exclude set with the following format.
exclude = {'amazon', 'microsoft'}
I want to exclude the words from new_vocd
dictionary that are present in the exclude set. Is it possible using set difference
option?
What are the other available ways? Any help is appreciated.
Expected output in terms of dictionary:
new_vocd = {'flipkart': [34,56], 'myntra': [78,89,98], 'ebay': [876,768]}