<commit_before>class HashTable(object):
    """Implment hash table"""

    def __init__(self, size=0000000):
        self._list_size = size
        self._hash_list = [[] for _hash in xrange(0, size)]

    def hash(self, key):
        if not isinstance(key, basestring):
            raise TypeError("key must be in string format")
        ord_val = 0
        for letter in key:
            ord_val += ord(letter)
        return ord_val % self._list_size

    def set(self, key, value):
        hash = self.hash(key)
        for item in self._hash_list[hash]:
            if item[0] == key:
                item[1] = value
                return
        self._hash_list[hash].append([key, value])
<commit_msg>created function for finding and returning hash data value<commit_after>class HashTable(object):
    """Implment hash table"""

    def __init__(self, size=0000000):
        self._list_size = size
        self._hash_list = [[] for _hash in xrange(0, size)]

    def hash(self, key):
        if not isinstance(key, basestring):
            raise TypeError("Key must be in string format")
        ord_val = 0
        for letter in key:
            ord_val += ord(letter)
        return ord_val % self._list_size

    def set(self, key, value):
        hash = self.hash(key)
        for item in self._hash_list[hash]:
            if item[0] == key:
                item[1] = value
                return
        self._hash_list[hash].append([key, value])

    def get(self, key):
        hash = self.hash(key)
        for item in self._hash_list[hash]:
            if item[0] == key:
                return item[1]
        raise KeyError("Key not found")

{'fraction_non_alphanumeric': 0.10789632308619651, 'fraction_numerical': 0.014466546112115732, 'mean_word_length': 1.985611510791367, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 2, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2826322', 'n_tokens_mistral': 506, 'n_tokens_neox': 479, 'n_words': 144}