Added functionality to iterate hashes