# [LeetCode](https://openset.github.io/leetcode)
LeetCode Problems' Solutions
[![Build Status](https://travis-ci.org/openset/leetcode.svg?branch=master)](https://travis-ci.org/openset/leetcode)
| # | Title | Solution | Difficulty |
| :-: | - | - | :-: |
| <span id="1">1</span> | [Two Sum](https://leetcode.com/problems/two-sum) | [Go](https://github.com/openset/leetcode/tree/master/solution/two-sum) | Easy |
| <span id="2">2</span> | [Add Two Numbers](https://leetcode.com/problems/add-two-numbers) | [Go](https://github.com/openset/leetcode/tree/master/solution/add-two-numbers) | Medium |
| <span id="3">3</span> | [Longest Substring Without Repeating Characters](https://leetcode.com/problems/longest-substring-without-repeating-characters) | [Go](https://github.com/openset/leetcode/tree/master/solution/longest-substring-without-repeating-characters) | Medium |
| <span id="4">4</span> | [Median of Two Sorted Arrays](https://leetcode.com/problems/median-of-two-sorted-arrays) | [Go](https://github.com/openset/leetcode/tree/master/solution/median-of-two-sorted-arrays) | Hard |
| <span id="5">5</span> | [Longest Palindromic Substring](https://leetcode.com/problems/longest-palindromic-substring) | [Go](https://github.com/openset/leetcode/tree/master/solution/longest-palindromic-substring) | Medium |
| <span id="6">6</span> | [ZigZag Conversion](https://leetcode.com/problems/zigzag-conversion) | [Go](https://github.com/openset/leetcode/tree/master/solution/zigzag-conversion) | Medium |
| <span id="7">7</span> | [Reverse Integer](https://leetcode.com/problems/reverse-integer) | [Go](https://github.com/openset/leetcode/tree/master/solution/reverse-integer) | Easy |
| <span id="8">8</span> | [String to Integer (atoi)](https://leetcode.com/problems/string-to-integer-atoi) | [Go](https://github.com/openset/leetcode/tree/master/solution/string-to-integer-atoi) | Medium |
| <span id="9">9</span> | [Palindrome Number](https://leetcode.com/problems/palindrome-number) | [Go](https://github.com/openset/leetcode/tree/master/solution/palindrome-number) | Easy |
| <span id="10">10</span> | [Regular Expression Matching](https://leetcode.com/problems/regular-expression-matching) | [Go](https://github.com/openset/leetcode/tree/master/solution/regular-expression-matching) | Hard |
| <span id="11">11</span> | [Container With Most Water](https://leetcode.com/problems/container-with-most-water) | [Go](https://github.com/openset/leetcode/tree/master/solution/container-with-most-water) | Medium |
| <span id="12">12</span> | [Integer to Roman](https://leetcode.com/problems/integer-to-roman) | [Go](https://github.com/openset/leetcode/tree/master/solution/integer-to-roman) | Medium |
| <span id="13">13</span> | [Roman to Integer](https://leetcode.com/problems/roman-to-integer) | [Go](https://github.com/openset/leetcode/tree/master/solution/roman-to-integer) | Easy |
| <span id="14">14</span> | [Longest Common Prefix](https://leetcode.com/problems/longest-common-prefix) | [Go](https://github.com/openset/leetcode/tree/master/solution/longest-common-prefix) | Easy |
| <span id="15">15</span> | [3Sum](https://leetcode.com/problems/3sum) | [Go](https://github.com/openset/leetcode/tree/master/solution/3sum) | Medium |
| <span id="16">16</span> | [3Sum Closest](https://leetcode.com/problems/3sum-closest) | [Go](https://github.com/openset/leetcode/tree/master/solution/3sum-closest) | Medium |
| <span id="17">17</span> | [Letter Combinations of a Phone Number](https://leetcode.com/problems/letter-combinations-of-a-phone-number) | [Go](https://github.com/openset/leetcode/tree/master/solution/letter-combinations-of-a-phone-number) | Medium |
| <span id="18">18</span> | [4Sum](https://leetcode.com/problems/4sum) | [Go](https://github.com/openset/leetcode/tree/master/solution/4sum) | Medium |
| <span id="19">19</span> | [Remove Nth Node From End of List](https://leetcode.com/problems/remove-nth-node-from-end-of-list) | [Go](https://github.com/openset/leetcode/tree/master/solution/remove-nth-node-from-end-of-list) | Medium |
| <span id="20">20</span> | [Valid Parentheses](https://leetcode.com/problems/valid-parentheses) | [Go](https://github.com/openset/leetcode/tree/master/solution/valid-parentheses) | Easy |
| <span id="21">21</span> | [Merge Two Sorted Lists](https://leetcode.com/problems/merge-two-sorted-lists) | [Go](https://github.com/openset/leetcode/tree/master/solution/merge-two-sorted-lists) | Easy |
| <span id="22">22</span> | [Generate Parentheses](https://leetcode.com/problems/generate-parentheses) | [Go](https://github.com/openset/leetcode/tree/master/solution/generate-parentheses) | Medium |
| <span id="23">23</span> | [Merge k Sorted Lists](https://leetcode.com/problems/merge-k-sorted-lists) | [Go](https://github.com/openset/leetcode/tree/master/solution/merge-k-sorted-lists) | Hard |
| <span id="24">24</span> | [Swap Nodes in Pairs](https://leetcode.com/problems/swap-nodes-in-pairs) | [Go](https://github.com/openset/leetcode/tree/master/solution/swap-nodes-in-pairs) | Medium |
| <span id="25">25</span> | [Reverse Nodes in k-Group](https://leetcode.com/problems/reverse-nodes-in-k-group) | [Go](https://github.com/openset/leetcode/tree/master/solution/reverse-nodes-in-k-group) | Hard |
| <span id="26">26</span> | [Remove Duplicates from Sorted Array](https://leetcode.com/problems/remove-duplicates-from-sorted-array) | [Go](https://github.com/openset/leetcode/tree/master/solution/remove-duplicates-from-sorted-array) | Easy |
| <span id="27">27</span> | [Remove Element](https://leetcode.com/problems/remove-element) | [Go](https://github.com/openset/leetcode/tree/master/solution/remove-element) | Easy |
| <span id="28">28</span> | [Implement strStr()](https://leetcode.com/problems/implement-strstr) | [Go](https://github.com/openset/leetcode/tree/master/solution/implement-strstr) | Easy |
| <span id="29">29</span> | [Divide Two Integers](https://leetcode.com/problems/divide-two-integers) | [Go](https://github.com/openset/leetcode/tree/master/solution/divide-two-integers) | Medium |
| <span id="30">30</span> | [Substring with Concatenation of All Words](https://leetcode.com/problems/substring-with-concatenation-of-all-words) | [Go](https://github.com/openset/leetcode/tree/master/solution/substring-with-concatenation-of-all-words) | Hard |
| <span id="31">31</span> | [Next Permutation](https://leetcode.com/problems/next-permutation) | [Go](https://github.com/openset/leetcode/tree/master/solution/next-permutation) | Medium |
| <span id="32">32</span> | [Longest Valid Parentheses](https://leetcode.com/problems/longest-valid-parentheses) | [Go](https://github.com/openset/leetcode/tree/master/solution/longest-valid-parentheses) | Hard |
| <span id="33">33</span> | [Search in Rotated Sorted Array](https://leetcode.com/problems/search-in-rotated-sorted-array) | [Go](https://github.com/openset/leetcode/tree/master/solution/search-in-rotated-sorted-array) | Medium |
| <span id="34">34</span> | [Find First and Last Position of Element in Sorted Array](https://leetcode.com/problems/find-first-and-last-position-of-element-in-sorted-array) | [Go](https://github.com/openset/leetcode/tree/master/solution/find-first-and-last-position-of-element-in-sorted-array) | Medium |
| <span id="35">35</span> | [Search Insert Position](https://leetcode.com/problems/search-insert-position) | [Go](https://github.com/openset/leetcode/tree/master/solution/search-insert-position) | Easy |
| <span id="36">36</span> | [Valid Sudoku](https://leetcode.com/problems/valid-sudoku) | [Go](https://github.com/openset/leetcode/tree/master/solution/valid-sudoku) | Medium |
| <span id="37">37</span> | [Sudoku Solver](https://leetcode.com/problems/sudoku-solver) | [Go](https://github.com/openset/leetcode/tree/master/solution/sudoku-solver) | Hard |
| <span id="38">38</span> | [Count and Say](https://leetcode.com/problems/count-and-say) | [Go](https://github.com/openset/leetcode/tree/master/solution/count-and-say) | Easy |
| <span id="39">39</span> | [Combination Sum](https://leetcode.com/problems/combination-sum) | [Go](https://github.com/openset/leetcode/tree/master/solution/combination-sum) | Medium |
| <span id="40">40</span> | [Combination Sum II](https://leetcode.com/problems/combination-sum-ii) | [Go](https://github.com/openset/leetcode/tree/master/solution/combination-sum-ii) | Medium |
| <span id="41">41</span> | [First Missing Positive](https://leetcode.com/problems/first-missing-positive) | [Go](https://github.com/openset/leetcode/tree/master/solution/first-missing-positive) | Hard |
| <span id="42">42</span> | [Trapping Rain Water](https://leetcode.com/problems/trapping-rain-water) | [Go](https://github.com/openset/leetcode/tree/master/solution/trapping-rain-water) | Hard |
| <span id="43">43</span> | [Multiply Strings](https://leetcode.com/problems/multiply-strings) | [Go](https://github.com/openset/leetcode/tree/master/solution/multiply-strings) | Medium |
| <span id="44">44</span> | [Wildcard Matching](https://leetcode.com/problems/wildcard-matching) | [Go](https://github.com/openset/leetcode/tree/master/solution/wildcard-matching) | Hard |
| <span id="45">45</span> | [Jump Game II](https://leetcode.com/problems/jump-game-ii) | [Go](https://github.com/openset/leetcode/tree/master/solution/jump-game-ii) | Hard |
| <span id="46">46</span> | [Permutations](https://leetcode.com/problems/permutations) | [Go](https://github.com/openset/leetcode/tree/master/solution/permutations) | Medium |
| <span id="47">47</span> | [Permutations II](https://leetcode.com/problems/permutations-ii) | [Go](https://github.com/openset/leetcode/tree/master/solution/permutations-ii) | Medium |
| <span id="48">48</span> | [Rotate Image](https://leetcode.com/problems/rotate-image) | [Go](https://github.com/openset/leetcode/tree/master/solution/rotate-image) | Medium |
| <span id="49">49</span> | [Group Anagrams](https://leetcode.com/problems/group-anagrams) | [Go](https://github.com/openset/leetcode/tree/master/solution/group-anagrams) | Medium |
| <span id="50">50</span> | [Pow(x, n)](https://leetcode.com/problems/powx-n) | [Go](https://github.com/openset/leetcode/tree/master/solution/powx-n) | Medium |
| <span id="51">51</span> | [N-Queens](https://leetcode.com/problems/n-queens) | [Go](https://github.com/openset/leetcode/tree/master/solution/n-queens) | Hard |
| <span id="52">52</span> | [N-Queens II](https://leetcode.com/problems/n-queens-ii) | [Go](https://github.com/openset/leetcode/tree/master/solution/n-queens-ii) | Hard |
| <span id="53">53</span> | [Maximum Subarray](https://leetcode.com/problems/maximum-subarray) | [Go](https://github.com/openset/leetcode/tree/master/solution/maximum-subarray) | Easy |
| <span id="54">54</span> | [Spiral Matrix](https://leetcode.com/problems/spiral-matrix) | [Go](https://github.com/openset/leetcode/tree/master/solution/spiral-matrix) | Medium |
| <span id="55">55</span> | [Jump Game](https://leetcode.com/problems/jump-game) | [Go](https://github.com/openset/leetcode/tree/master/solution/jump-game) | Medium |
| <span id="56">56</span> | [Merge Intervals](https://leetcode.com/problems/merge-intervals) | [Go](https://github.com/openset/leetcode/tree/master/solution/merge-intervals) | Medium |
| <span id="57">57</span> | [Insert Interval](https://leetcode.com/problems/insert-interval) | [Go](https://github.com/openset/leetcode/tree/master/solution/insert-interval) | Hard |
| <span id="58">58</span> | [Length of Last Word](https://leetcode.com/problems/length-of-last-word) | [Go](https://github.com/openset/leetcode/tree/master/solution/length-of-last-word) | Easy |
| <span id="59">59</span> | [Spiral Matrix II](https://leetcode.com/problems/spiral-matrix-ii) | [Go](https://github.com/openset/leetcode/tree/master/solution/spiral-matrix-ii) | Medium |
| <span id="60">60</span> | [Permutation Sequence](https://leetcode.com/problems/permutation-sequence) | [Go](https://github.com/openset/leetcode/tree/master/solution/permutation-sequence) | Medium |
| <span id="61">61</span> | [Rotate List](https://leetcode.com/problems/rotate-list) | [Go](https://github.com/openset/leetcode/tree/master/solution/rotate-list) | Medium |
| <span id="62">62</span> | [Unique Paths](https://leetcode.com/problems/unique-paths) | [Go](https://github.com/openset/leetcode/tree/master/solution/unique-paths) | Medium |
| <span id="63">63</span> | [Unique Paths II](https://leetcode.com/problems/unique-paths-ii) | [Go](https://github.com/openset/leetcode/tree/master/solution/unique-paths-ii) | Medium |
| <span id="64">64</span> | [Minimum Path Sum](https://leetcode.com/problems/minimum-path-sum) | [Go](https://github.com/openset/leetcode/tree/master/solution/minimum-path-sum) | Medium |
| <span id="65">65</span> | [Valid Number](https://leetcode.com/problems/valid-number) | [Go](https://github.com/openset/leetcode/tree/master/solution/valid-number) | Hard |
| <span id="66">66</span> | [Plus One](https://leetcode.com/problems/plus-one) | [Go](https://github.com/openset/leetcode/tree/master/solution/plus-one) | Easy |
| <span id="67">67</span> | [Add Binary](https://leetcode.com/problems/add-binary) | [Go](https://github.com/openset/leetcode/tree/master/solution/add-binary) | Easy |
| <span id="68">68</span> | [Text Justification](https://leetcode.com/problems/text-justification) | [Go](https://github.com/openset/leetcode/tree/master/solution/text-justification) | Hard |
| <span id="69">69</span> | [Sqrt(x)](https://leetcode.com/problems/sqrtx) | [Go](https://github.com/openset/leetcode/tree/master/solution/sqrtx) | Easy |
| <span id="70">70</span> | [Climbing Stairs](https://leetcode.com/problems/climbing-stairs) | [Go](https://github.com/openset/leetcode/tree/master/solution/climbing-stairs) | Easy |
| <span id="71">71</span> | [Simplify Path](https://leetcode.com/problems/simplify-path) | [Go](https://github.com/openset/leetcode/tree/master/solution/simplify-path) | Medium |
| <span id="72">72</span> | [Edit Distance](https://leetcode.com/problems/edit-distance) | [Go](https://github.com/openset/leetcode/tree/master/solution/edit-distance) | Hard |
| <span id="73">73</span> | [Set Matrix Zeroes](https://leetcode.com/problems/set-matrix-zeroes) | [Go](https://github.com/openset/leetcode/tree/master/solution/set-matrix-zeroes) | Medium |
| <span id="74">74</span> | [Search a 2D Matrix](https://leetcode.com/problems/search-a-2d-matrix) | [Go](https://github.com/openset/leetcode/tree/master/solution/search-a-2d-matrix) | Medium |
| <span id="75">75</span> | [Sort Colors](https://leetcode.com/problems/sort-colors) | [Go](https://github.com/openset/leetcode/tree/master/solution/sort-colors) | Medium |
| <span id="76">76</span> | [Minimum Window Substring](https://leetcode.com/problems/minimum-window-substring) | [Go](https://github.com/openset/leetcode/tree/master/solution/minimum-window-substring) | Hard |
| <span id="77">77</span> | [Combinations](https://leetcode.com/problems/combinations) | [Go](https://github.com/openset/leetcode/tree/master/solution/combinations) | Medium |
| <span id="78">78</span> | [Subsets](https://leetcode.com/problems/subsets) | [Go](https://github.com/openset/leetcode/tree/master/solution/subsets) | Medium |
| <span id="79">79</span> | [Word Search](https://leetcode.com/problems/word-search) | [Go](https://github.com/openset/leetcode/tree/master/solution/word-search) | Medium |
| <span id="80">80</span> | [Remove Duplicates from Sorted Array II](https://leetcode.com/problems/remove-duplicates-from-sorted-array-ii) | [Go](https://github.com/openset/leetcode/tree/master/solution/remove-duplicates-from-sorted-array-ii) | Medium |
| <span id="81">81</span> | [Search in Rotated Sorted Array II](https://leetcode.com/problems/search-in-rotated-sorted-array-ii) | [Go](https://github.com/openset/leetcode/tree/master/solution/search-in-rotated-sorted-array-ii) | Medium |
| <span id="82">82</span> | [Remove Duplicates from Sorted List II](https://leetcode.com/problems/remove-duplicates-from-sorted-list-ii) | [Go](https://github.com/openset/leetcode/tree/master/solution/remove-duplicates-from-sorted-list-ii) | Medium |
| <span id="83">83</span> | [Remove Duplicates from Sorted List](https://leetcode.com/problems/remove-duplicates-from-sorted-list) | [Go](https://github.com/openset/leetcode/tree/master/solution/remove-duplicates-from-sorted-list) | Easy |
| <span id="84">84</span> | [Largest Rectangle in Histogram](https://leetcode.com/problems/largest-rectangle-in-histogram) | [Go](https://github.com/openset/leetcode/tree/master/solution/largest-rectangle-in-histogram) | Hard |
| <span id="85">85</span> | [Maximal Rectangle](https://leetcode.com/problems/maximal-rectangle) | [Go](https://github.com/openset/leetcode/tree/master/solution/maximal-rectangle) | Hard |
| <span id="86">86</span> | [Partition List](https://leetcode.com/problems/partition-list) | [Go](https://github.com/openset/leetcode/tree/master/solution/partition-list) | Medium |
| <span id="87">87</span> | [Scramble String](https://leetcode.com/problems/scramble-string) | [Go](https://github.com/openset/leetcode/tree/master/solution/scramble-string) | Hard |
| <span id="88">88</span> | [Merge Sorted Array](https://leetcode.com/problems/merge-sorted-array) | [Go](https://github.com/openset/leetcode/tree/master/solution/merge-sorted-array) | Easy |
| <span id="89">89</span> | [Gray Code](https://leetcode.com/problems/gray-code) | [Go](https://github.com/openset/leetcode/tree/master/solution/gray-code) | Medium |
| <span id="90">90</span> | [Subsets II](https://leetcode.com/problems/subsets-ii) | [Go](https://github.com/openset/leetcode/tree/master/solution/subsets-ii) | Medium |
| <span id="91">91</span> | [Decode Ways](https://leetcode.com/problems/decode-ways) | [Go](https://github.com/openset/leetcode/tree/master/solution/decode-ways) | Medium |
| <span id="92">92</span> | [Reverse Linked List II](https://leetcode.com/problems/reverse-linked-list-ii) | [Go](https://github.com/openset/leetcode/tree/master/solution/reverse-linked-list-ii) | Medium |
| <span id="93">93</span> | [Restore IP Addresses](https://leetcode.com/problems/restore-ip-addresses) | [Go](https://github.com/openset/leetcode/tree/master/solution/restore-ip-addresses) | Medium |
| <span id="94">94</span> | [Binary Tree Inorder Traversal](https://leetcode.com/problems/binary-tree-inorder-traversal) | [Go](https://github.com/openset/leetcode/tree/master/solution/binary-tree-inorder-traversal) | Medium |
| <span id="95">95</span> | [Unique Binary Search Trees II](https://leetcode.com/problems/unique-binary-search-trees-ii) | [Go](https://github.com/openset/leetcode/tree/master/solution/unique-binary-search-trees-ii) | Medium |
| <span id="96">96</span> | [Unique Binary Search Trees](https://leetcode.com/problems/unique-binary-search-trees) | [Go](https://github.com/openset/leetcode/tree/master/solution/unique-binary-search-trees) | Medium |
| <span id="97">97</span> | [Interleaving String](https://leetcode.com/problems/interleaving-string) | [Go](https://github.com/openset/leetcode/tree/master/solution/interleaving-string) | Hard |
| <span id="98">98</span> | [Validate Binary Search Tree](https://leetcode.com/problems/validate-binary-search-tree) | [Go](https://github.com/openset/leetcode/tree/master/solution/validate-binary-search-tree) | Medium |
| <span id="99">99</span> | [Recover Binary Search Tree](https://leetcode.com/problems/recover-binary-search-tree) | [Go](https://github.com/openset/leetcode/tree/master/solution/recover-binary-search-tree) | Hard |
| <span id="100">100</span> | [Same Tree](https://leetcode.com/problems/same-tree) | [Go](https://github.com/openset/leetcode/tree/master/solution/same-tree) | Easy |
......
---
### 欢迎各位同学Star、提交Pr、反馈问题。
[\[阅读原文\]](https://openset.github.io/leetcode)
有疑问加站长微信联系(非本文作者)