Data Structure



Array

# Title Acceptance Difficulty Solution Algorithm
0001 Two Sum 47.6% Easy Go hash table
0004 Median of Two Sorted Arrays 36.8% Hard Go binary search
0011 Container With Most Water 61.3% Medium Go two pointer
0015 3Sum 25.5% Medium Go two pointer
0016 3Sum Closest 43.0% Medium Go two pointer
0018 4Sum 37.2% Medium Go two pointer
0026 Remove Duplicates from Sorted Array 48.6% Easy Go two pointer
0027 Remove Element 57.4% Easy Go two pointer
0030 Substring with Concatenation of All Words 29.2% Hard Go two pointer
0033 Search in Rotated Sorted Array 36.4% Medium Go binary search
0034 Find First and Last Position of Element in Sorted Array 39.0% Medium Go binary search
0035 Search Insert Position 45.2% Easy Go binary search
0036 Valid Sudoku 58.4% Medium Go dfs
0037 Sudoku Solver 59.5% Hard Go dfs
0041 First Missing Positive 37.6% Hard Go bit map
0042 Trapping Rain Water 48.6% Hard Go two pointer

LinkedList

# Title Acceptance Difficulty Solution Algorithm
0002 Add Two Numbers 36.6% Medium Go
0019 Remove Nth Node From End of List 37.5% Medium Go two pointer
0021 Merge Two Sorted Lists 59.7% Easy Go
0023 Merge k Sorted Lists 48.8% Hard Go
0024 Swap Nodes in Pairs 64.3% Medium Go
0025 Reverse Nodes in k-Group 56.2% Hard Go

Math

# Title Acceptance Difficulty Solution Algorithm
0007 Reverse Integer 33.6% Easy Go
0008 String to Integer (atoi) 19.1% Medium Go
0009 Palindrome Number 57.1% Easy Go
0012 Integer to Roman 62.6% Medium Go
0013 Roman to Integer 60.7% Easy Go
0029 Divide Two Integers 19.3% Medium Go
0031 Next Permutation 32.8% Medium Go

Stack

# Title Acceptance Difficulty Solution Algorithm
0020 Valid Parentheses 40.9% Easy Go
0032 Longest Valid Parentheses 29.7% Hard Go

String

# Title Acceptance Difficulty Solution Algorithm
0003 Longest Substring Without Repeating Characters 32.9% Medium Go
0005 Longest Palindromic Substring 28.5% Medium Go
0006 ZigZag Conversion 46.7% Medium Go
0010 Regular Expression Matching 26.0% Hard Go
0014 Longest Common Prefix 36.2% Easy Go
0017 Letter Combinations of a Phone Number 52.5% Medium Go
0028 Implement strStr() 39.5% Easy Go
0038 Count and Say 54.4% Easy Go
0043 Multiply Strings 41.6% Medium Go
0415 Add Strings 49.5% Easy Go

Tree

# Title Acceptance Difficulty Solution Algorithm
0022 Generate Parentheses 73.3% Medium Go dfs.iterative
Go dfs.recursive
0039 Combination Sum 68.4% Medium Go dfs.recursive
0040 Combination Sum II 60.1% Medium Go dfs.recursive
0094 Binary Tree Inorder Traversal 70.2% Medium Go dfs.morris.break
Go dfs.morris.keep
Go dfs.recursive
Go dfs.stack
0098 Validate Binary Search Tree 28.9% Medium Go dfs.recursive
0099 Recover Binary Search Tree 54.9% Hard Go dfs.recursive
0100 Same Tree 56.5% Easy Go dfs.recursive
0101 Symmetric Tree 50.0% Easy Go dfs.recursive
0102 Binary Tree Level Order Traversal 60.9% Medium Go dfs.recursive
0103 Binary Tree Zigzag Level Order Traversal 53.6% Medium Go dfs.recursive