Implement a Dictionary in Swift
4 min readMay 27, 2019
It is not just a HashMap…but how can we implement our own version of a Dictionary in Swift?
Dictionaries are a data type that are a function of hash table. Dictionaries provide fast access to the values it stores. The table stores entries as a key-value pair (with the value representing any object).
var myDictionary: [Int: Int] = [:]