# Hash

­

## Hash Table

A hash table is a data structure that maps keys to values for highly effient lookup.

November 14th, 2015|Categories: DS and Algorithms, Hash|Tags: , |

## [Leetcode] Contains Duplicate

Given an array of integers, find if the array contains any duplicates.

November 14th, 2015|Categories: DS and Algorithms, Hash||

## [Leetcode] Longest Substring Without Repeating Characters

Given a string, find the length of the longest substring without repeating characters.

November 14th, 2015|Categories: DS and Algorithms, Hash||

## [Leetcode] Contains Duplicate II

Find if a duplicate exists among the recent k numbers.

November 14th, 2015|Categories: DS and Algorithms, Hash||

## [Leetcode] Swap Nodes in Pairs

November 14th, 2015|Categories: DS and Algorithms, Hash, Linked List||

## [Leetcode] Letter Combinations of a Phone Number

Given a digit string, return all possible letter combinations that the number could represent.

November 14th, 2015|Categories: DS and Algorithms, Hash, Recursion||

## [Leetcode] Happy Number

Write an algorithm to determine if a number is "happy".

November 14th, 2015|Categories: DS and Algorithms, Hash, Math||

## [Leetcode] Single Number

Given an array of integers, every element appears twice except for one. Find that single one.

November 23rd, 2015|Categories: Bit Manipulation, DS and Algorithms, Hash||

## [Leetcode] Single Number II

Given an array of integers, every element appears three times except for one. Find that single one.

November 25th, 2015|Categories: Bit Manipulation, DS and Algorithms, Hash||

## [Leetcode] Single Number III

Given an array of numbers nums, in which exactly two elements appear only once and all the other elements appear exactly twice. Find the two elements that appear only once.

## [Leetcode] Repeated DNA Sequences

Write a function to find all the 10-letter-long sequences (substrings) that occur more than once in a DNA molecule.

November 29th, 2015|Categories: Bit Manipulation, DS and Algorithms, Hash||

## [Leetcode] Add and Search Word – Data structure design

Design a data structure that supports add(word) and search(word).

December 1st, 2015|Categories: DS and Algorithms, Hash, Searching, Tree||

## [Leetcode] Isomorphic Strings

Given two strings s and t, determine if they are isomorphic.

December 1st, 2015|Categories: DS and Algorithms, Hash||

## [Leetcode] Valid Anagram

Given two strings s and t, write a function to determine if t is an anagram of s.

December 7th, 2015|Categories: DS and Algorithms, Hash, String||

## [Leetcode] Majority Element

Given an array of size n, find the majority element. The majority element is the element that appears more than ⌊ n/2 ⌋ times.

December 7th, 2015|Categories: Array, DS and Algorithms, Hash, Sorting||

## [Leetcode] Valid Sudoku

Given a sudoku, determine if it is valid.

December 10th, 2015|Categories: DS and Algorithms, Hash||

## [Leetcode] Word Pattern

Given a pattern and a string str, find if str follows the same pattern.

December 11th, 2015|Categories: DS and Algorithms, Hash, String||

## [Leetcode] Bulls and Cows

Bulls and Cows is an interesting problem that could be solved by hash table in an interesting way.

December 11th, 2015|Categories: DS and Algorithms, Hash, String||