hash table?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • datulaida
    New Member
    • May 2007
    • 14

    #1

    hash table?

    how to build hash table in python?
    any suggestion?
    thanks..
  • bvdet
    Recognized Expert Specialist
    • Oct 2006
    • 2851

    #2
    Originally posted by datulaida
    how to build hash table in python?
    any suggestion?
    thanks..
    The Python equivalent of a hash table is a dictionary. Example:
    [code=Python]>>> dd = {'a': 1, 'b': 2, 'c': 3}
    >>> dd['a']
    1
    >>> [/code]

    Comment

    • datulaida
      New Member
      • May 2007
      • 14

      #3
      Originally posted by bvdet
      The Python equivalent of a hash table is a dictionary. Example:
      [code=Python]>>> dd = {'a': 1, 'b': 2, 'c': 3}
      >>> dd['a']
      1
      >>> [/code]
      thank you for your help.. but i want to build hash tables..

      Comment

      • bvdet
        Recognized Expert Specialist
        • Oct 2006
        • 2851

        #4
        Originally posted by datulaida
        thank you for your help.. but i want to build hash tables..
        From Python Essential Reference:
        Originally posted by Python Essential Reference
        Dictionaries are the only built-in mapping type and are Python's version of a hash table or associative array.

        Comment

        Working...