Insert the following keys in the hash table in thesequence that they appear below
• A hash table has size 11, with the indices numbered from 0 to 10. It is currently empty (no elements yet). • The hashing function is defined as H(k) = k % 11 . Collisions are resolved by chaining. Insert the following keys in the hash table in the sequence that they appear below: 135795 245796 355795 465798 575795 685800 795795 905802 1015795 1125804 1. What is H(685800)? 2. What is H(1125804)? 3. How many nodes are there in the linked list stored at index 0 of the hash table? 4. How many keys map to index 6? 5. How many keys map to index 3? A graph can be used to show relationships. You are given the set of vertices (People) and set of edges (Friendship) • People . (Twilight, Yor, Anya, Yuri, Damian, Donovan, Becky, Sylvia, Franky} Friendship ((Twilight, Yor) (Twilight, Anya) (Yor Anya) (Yor, Yuri) (Anya, Damian) (Anya, Becky) (Damian, Donovan) (Sylvia, Twilight) (Franky, Twilight) (Franky, Anya)} () indicates bidirectional relationships so Twilight is friends with Yor. And Yor is friends with Twilight 6. Who are the Friends of Damian? 7. Who are the Friends of Franky? 8. Who are the Friends of Anya? 9. Who are the Friends of Franky? 10. Who are the friends of Twilight? 11. Friend of friends of Becky? 12. Friend of friends of Yor?
Insert the following keys in the hash table in the sequence that they appear below
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am