单项选择题
您正在编写自定义字典。该自定义字典类名为MyDictionary。您需要确保该字典是类型安全的字典。您应该使用哪个代码段?()
A.A
B.B
C.C
D.D
相关考题
-
单项选择题
WhatkindofobjectdoesthegenericDictionaryenumeratorreturn?()
A. Object
B. Generic
C. Key
D. Value -
单项选择题
YouworkastheapplicationdeveloperatHi-Tech.com.YoucreateanewcustomdictionarynamedMyDictionary.ChoosethecodesegmentwhichwillensurethatMyDictionaryistypesafe?()
A. Class MyDictionary Implements Dictionary (Of String,String)
B. Class MyDictionary Inherits HashTable
C. Class MyDictionary Implements IDictionary
D. Class MyDictionary End Class Dim t as New Dictionary (Of String, String) Dim dict As MyDIctionary= CType (t,MyDictionary) -
单项选择题
YouworkasanapplicationdeveloperatCER-Tech.com.Cert-Tech.comusesVisualstudio.NET2005asitsApplicationDevelopmentplatform.Youaredevelopinga.NETFramework2.0applicationusedtostoreatype-safelistofnamesande-mailaddresses.Thelistwillbepopulatedallatonesfromthesorteddatawhichmeansyouwillnotalwaysneedtoperforminsertionordeletionoperationsonthedata.Youarerequiredtochooseadatastructurethatoptimizesmemoryuseandhasgoodperformance.Whatshouldyoudo?()
A. The System.Collections.Generic.SortedList class should be used
B. The System.Collections.HashTable class should be used
C. The System.Collections.Generic.SortedDictionary class should be used
D. The System.Collections.SortedList class should be used
