Question:You are writing a custom dictionary. The custom-dictionary class is named MyDictionary. You need to ensure that the dictionary is type safe. Which code segment should you use? 

A class MyDictionary : IDictionary 

B class MyDictionary { ... }
Dictionary<string, string> t =
new Dictionary<string, string>();
MyDictionary dictionary = (MyDictionary)t; 

C class MyDictionary : Dictionary<string, string> 

D class MyDictionary : HashTable 

+ Answer
+ Report
Total Preview: 1286

Copyright © 2024. Powered by Intellect Software Ltd