I made a simple program to see just how much faster a dictionary is than a hash table. I ran the test 20 times for each data set and the results were close each time. A GUID as the key and a boolean as the data.
This is the results of the last test for each dataset.
Time in Milliseconds for 100,000 keys | Dictionary | Hash Table |
Inserting | 34.41264 | 76.0970 |
Reading | 18.9005 | 31.1648 |
Deleting | 21.2474 | 30.4655 |
Time in Seconds for 10,000,000 keys | Dictionary | Hash Table |
Inserting | 6.5704143 | 26.9096540 |
Reading | 3.1362891 | 5.6670613 |
Deleting | 3.4623316 | 4.8830676 |
No comments:
Post a Comment