Added iterate() method. Optimised HashMap.
Deleted the Double classes because they have unnecessary overhead.