dictionary
dict.add(34,"ABC");
dist.add(34,"XYZ")
foreach(int i in dist.key)
{}
console.writeline("Key"+i+"value"+dist[i])
dictionary
dict.add(34,"ABC");
dist.add(34,"XYZ")
foreach(int i in dist.key)
{}
console.writeline("Key"+i+"value"+dist[i])
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Arnab MukherjeeRank #879 · 2.5K reputationPosted Jul 3, 2021, 4:57 AM EDT
Rajanikant HawaldarRank #110 · 20.2K reputationPosted Jul 3, 2021, 5:15 AM EDT
https://www.c-sharpcorner.com/uploadfile/mahesh/dictionary-in-C-Sharp/
your adding duplicate key 34, keys are unic in dictoinary
Sachin SinghRank #66 · 26.2K reputationPosted Jul 3, 2021, 5:29 AM EDT
Amit Kumar SinghRank #562 · 4.3K reputationPosted Jul 3, 2021, 5:55 AM EDT
Satya KarkiRank #78 · 24.6K reputationPosted Jul 3, 2021, 4:48 AM EDT