Courses
Tutorials
Interview Prep
DSA
Practice Problems
C
C++
Java
Python
JavaScript
Data Science
Machine Learning
Courses
Linux
DevOps
Similar Topics
Web Technologies
32.1K+ articles
DSA
20.4K+ articles
Python
19.6K+ articles
Experiences
15.8K+ articles
Interview Experiences
14.5K+ articles
Difference Between
3.1K+ articles
C#
2.0K+ articles
CSharp-method
701+ articles
CSharp-Generic-Namespace
140+ articles
CSharp-Collections-Hashtable
21+ articles
CSharp Dictionary Class
14 posts
Recent Articles
Popular Articles
C# Hashtable vs Dictionary
Last Updated: 11 July 2025
In C# both Hashtable and Dictionary are used to store key-value pairs. Understanding the difference between Hashtable and Dictionary plays a very important role in choosin...
read more
Difference Between
C#
CSharp-Collections-Hashtable
CSharp Dictionary Class
Dictionary in C#
Last Updated: 23 April 2026
Dictionary in C# is a generic collection that stores key-value pairs. The working of Dictionary is quite similar to the non-generic hashtable. It's a generic type, which i...
read more
C#
CSharp-Generic-Namespace
CSharp Dictionary Class
Check if Two Dictionary Objects are Equal in C#
Last Updated: 11 July 2025
In C#, a DictionaryTKey, TValue is a collection of key-value pairs. When we work with dictionaries, we may need to check if two dictionaries are equal. This means they con...
read more
C#
CSharp-method
CSharp-Generic-Namespace
CSharp Dictionary Class
C# | Get an enumerator that iterates through the Dictionary
Last Updated: 11 July 2025
DictionaryTKey, TValue.GetEnumerator method is used to return an enumerator that iterates through the DictionaryTKey, TValue.Syntax:public System.Collections.Generic.Dicti...
read more
C#
CSharp-method
CSharp-Generic-Namespace
CSharp Dictionary Class
C# | Dictionary.Item[] Property
Last Updated: 11 July 2025
This property is used to get or set the value associated with the specified key in the Dictionary.Syntax:public TValue this[TKey key] { get; set; }Here, key is the Key of ...
read more
C#
CSharp-Generic-Namespace
CSharp Dictionary Class
C# | Dictionary.ContainsKey() Method
Last Updated: 11 July 2025
This method is used to check whether the DictionaryTKey,TValue contains the specified key or not.Syntax:public bool ContainsKey (TKey key);Here, the key is the Key which i...
read more
C#
CSharp-method
CSharp-Generic-Namespace
CSharp Dictionary Class
C# | Dictionary.ContainsValue() Method
Last Updated: 11 July 2025
This method is used to check whether the DictionaryTKey,TValue contains a specific value or not.Syntax:public bool ContainsValue (TValue value);Here, the value is the Valu...
read more
C#
CSharp-method
CSharp-Generic-Namespace
CSharp Dictionary Class
C# | Dictionary.Remove Method
Last Updated: 11 July 2025
This method is used to remove the value with the specified key from the DictionaryTKey,TValue.Syntax:public bool Remove (TKey key);Return Value: This method returns true i...
read more
C#
CSharp-method
CSharp-Generic-Namespace
CSharp Dictionary Class
C# | Dictionary.Clear Method
Last Updated: 11 July 2025
This method is used to remove all key/value pairs from the DictionaryTKey,TValue.Syntax:public void Clear ();Below are the programs to illustrate the use of above-discusse...
read more
C#
CSharp-method
CSharp-Generic-Namespace
CSharp Dictionary Class
C# | Dictionary.Add() Method
Last Updated: 11 July 2025
DictionaryTKey,TValue.Add() Method is used to add a specified key and value to the dictionary. Syntax:public void Add (TKey key, TValue value);Parameters:key: It is the ke...
read more
C#
CSharp-method
CSharp-Generic-Namespace
CSharp Dictionary Class
C# | Dictionary.Values Property
Last Updated: 11 July 2025
This property is used to get a collection containing the values in the DictionaryTKey,TValue.Syntax:public System.Collections.Generic.DictionaryTKey, TValue.KeyCollection ...
read more
C#
CSharp-Generic-Namespace
CSharp Dictionary Class
C# | Dictionary.Keys Property
Last Updated: 11 July 2025
This property is used to get a collection containing the keys in the Dictionary.Syntax:public System.Collections.Generic.DictionaryTKey, TValue.KeyCollection Keys { get; }...
read more
C#
CSharp-Generic-Namespace
CSharp Dictionary Class
C# | Dictionary.Count Property
Last Updated: 11 July 2025
This property is used to get the number of key/value pairs contained in the Dictionary.Syntax:public int Count { get; }Return Value : The number of key/value pairs contain...
read more
C#
CSharp-Generic-Namespace
CSharp Dictionary Class
C# Dictionary Class
Last Updated: 11 July 2025
In C#, the Dictionary class is the part of the System.Collections.Generic namespace. It is a Collection that stores Key-value pairs. Each key in the dictionary is unique a...
read more
C#
CSharp-Generic-Namespace
CSharp Dictionary Class