Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Challenge: Creating Hash Table with String Keys | Advanced Data Structures
Algorithms and Data Structures Overview
course content

Зміст курсу

Algorithms and Data Structures Overview

Algorithms and Data Structures Overview

1. Introduction to ADS
2. List and Array
3. Advanced Data Structures
4. Graphs

Challenge: Creating Hash Table with String Keys

Завдання

In the previous chapter, we created a hash table with a function that can work with numerical keys. Now you will implement a hash function that will work with keys of type string.

This particular hash function must calculate the hash value by summing the ASCII values of the characters in the key string. Doing so transforms variable-length input (keys of different lengths) into a fixed-size hash value. This hash value is then modulo with the size of the hash table to determine the index where the key-value pair should be stored.

Your task is to implement this hash function by filling the gaps in the ._hash_function() method of the HashTable class.

Завдання

In the previous chapter, we created a hash table with a function that can work with numerical keys. Now you will implement a hash function that will work with keys of type string.

This particular hash function must calculate the hash value by summing the ASCII values of the characters in the key string. Doing so transforms variable-length input (keys of different lengths) into a fixed-size hash value. This hash value is then modulo with the size of the hash table to determine the index where the key-value pair should be stored.

Your task is to implement this hash function by filling the gaps in the ._hash_function() method of the HashTable class.

Перейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів

Все було зрозуміло?

Секція 3. Розділ 5
toggle bottom row

Challenge: Creating Hash Table with String Keys

Завдання

In the previous chapter, we created a hash table with a function that can work with numerical keys. Now you will implement a hash function that will work with keys of type string.

This particular hash function must calculate the hash value by summing the ASCII values of the characters in the key string. Doing so transforms variable-length input (keys of different lengths) into a fixed-size hash value. This hash value is then modulo with the size of the hash table to determine the index where the key-value pair should be stored.

Your task is to implement this hash function by filling the gaps in the ._hash_function() method of the HashTable class.

Завдання

In the previous chapter, we created a hash table with a function that can work with numerical keys. Now you will implement a hash function that will work with keys of type string.

This particular hash function must calculate the hash value by summing the ASCII values of the characters in the key string. Doing so transforms variable-length input (keys of different lengths) into a fixed-size hash value. This hash value is then modulo with the size of the hash table to determine the index where the key-value pair should be stored.

Your task is to implement this hash function by filling the gaps in the ._hash_function() method of the HashTable class.

Перейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів

Все було зрозуміло?

Секція 3. Розділ 5
toggle bottom row

Challenge: Creating Hash Table with String Keys

Завдання

In the previous chapter, we created a hash table with a function that can work with numerical keys. Now you will implement a hash function that will work with keys of type string.

This particular hash function must calculate the hash value by summing the ASCII values of the characters in the key string. Doing so transforms variable-length input (keys of different lengths) into a fixed-size hash value. This hash value is then modulo with the size of the hash table to determine the index where the key-value pair should be stored.

Your task is to implement this hash function by filling the gaps in the ._hash_function() method of the HashTable class.

Завдання

In the previous chapter, we created a hash table with a function that can work with numerical keys. Now you will implement a hash function that will work with keys of type string.

This particular hash function must calculate the hash value by summing the ASCII values of the characters in the key string. Doing so transforms variable-length input (keys of different lengths) into a fixed-size hash value. This hash value is then modulo with the size of the hash table to determine the index where the key-value pair should be stored.

Your task is to implement this hash function by filling the gaps in the ._hash_function() method of the HashTable class.

Перейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів

Все було зрозуміло?

Завдання

In the previous chapter, we created a hash table with a function that can work with numerical keys. Now you will implement a hash function that will work with keys of type string.

This particular hash function must calculate the hash value by summing the ASCII values of the characters in the key string. Doing so transforms variable-length input (keys of different lengths) into a fixed-size hash value. This hash value is then modulo with the size of the hash table to determine the index where the key-value pair should be stored.

Your task is to implement this hash function by filling the gaps in the ._hash_function() method of the HashTable class.

Перейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
Секція 3. Розділ 5
Перейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
We're sorry to hear that something went wrong. What happened?
some-alt