Lunes, Enero 16, 2012

Case Study 5

 
 In computer science, a hash table or hash map is a data structure that uses a hash function to map identifying values, known as keys (e.g., a person's name), to their associated values (e.g., their telephone number).




  • Secret Key Cryptography (SKC): Uses a single key for both encryption and decryption
  • Public Key Cryptography (PKC): Uses one key for encryption and another for decryption
  • Hash Functions: Uses a mathematical transformation to irreversibly "encrypt" information 

CASE STUDY 4

 1. What is hash collision?
In computer science, a hash collision is a situation that occurs when two distinct inputs into a hash function produce identical outputs.

 2. What really happens during a hash collision? Include an image

Hash tables may be used as in-memory data structures. Hash tables may also be adopted for use with persistent data structures; database indexes commonly use disk-based data structures based on hash tables.

3. What are the ways and methods to resolve hash collision? Explain Each

If keys are small integers, we can use an array to implement a symbol table, by interpreting the key as an array index so that we can store the value associated with key i in array position i. In this section, we consider hashing, an extension of this simple method that handles more complicated types of keys. We reference key-value pairs using arrays by doing arithmetic operations to transform keys into array indices.