cssmason / algorithm-practice

Solutions to LeetCode

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

algorithm-practice

No. Title Solution Difficulty Tag
0001 Two Sum Python Easy Blind75, Grind75, Array
0002 Add Two Numbers Python Medium
0003 Longest Substring Without Repeating Characters Python Medium Blind75, Grind75, String
0005 Longest Palindromic Substring Python Medium Blind75, Grind75, String
0006 Zigzag Conversion Python Medium
0007 Reverse Integer Python Medium
0008 String to Integer (atoi) Python Medium Grind75, String
0011 Container With Most Water Python Medium Blind75, Grind75, Array
0012 Integer to Roman Python Medium
0013 Roman to Integer Python Easy
0014 Longest Common Prefix Python Easy
0015 3Sum Python Medium Blind75, Grind75, Array
0017 Letter Combinations of a Phone Number Python Medium Grind75, Recursion
0019 Remove Nth Node From End of List Python Medium Blind75, Linked List
0020 Valid Parentheses Python Easy Blind75, Grind75, String, Stack
0021 Merge Two Sorted Lists Python Easy Blind75, Grind75, Linked List
0022 Generate Parentheses Python Medium
0024 Swap Nodes in Pairs Python Medium
0026 Remove Duplicates from Sorted Array Python Easy
0027 Remove Element Python Easy
0028 Find the Index of the First Occurrence in a String Python Easy
0033 Search in Rotated Sorted Array Python Medium Blind75, Grind75, Array, Binary Search
0034 Find First and Last Position of Element in Sorted Array Python Medium Binary Search
0035 Search Insert Position Python Easy
0036 Valid Sudoku Python Medium
0038 Count and Say Python Medium
0039 Combination Sum Python Medium Blind75,Grind75, Array, Dynamic Programming
0042 Trapping Rain Water Python Hard Grind75, Stack
0043 Multiply Strings Python Medium
0046 Permutations Python Medium Grind75, Recursion
0047 Permutations II Python Medium
0048 Rotate Image Python Medium Blind75, Matrix
0049 Group Anagrams Python Medium Blind75, String
0053 Maximum Subarray Python Medium Blind75, Grind75, Array
0054 Spiral Matrix Python Medium Blind75, Grind75, Matrix
0055 Jump Game Python Medium Blind75, Dynamic Programming
0056 Merge Intervals Python Medium Blind75, Grind75, Interval, Sorting, Array
0057 Insert Interval Python Medium Blind75, Grind75, Interval
0058 Length of Last Word Python Easy
0061 Rotate List Python Medium
0062 Unique Paths Python Medium Blind75, Grind75, Dynamic Programming
0067 Add Binary Python Easy Grind75, Binary
0070 Climbing Stairs Python Easy
0071 Simplify Path Python Medium
0073 Set Matrix Zeroes Python Medium Blind75, Matrix
0074 Search a 2D Matrix Python Medium
0075 Sort Colors Python Medium Grind75, Array
0076 Minimum Window Substring Python Hard Blind75, Grind75, String
0078 Subsets Python Medium Grind75, Recursion
0079 Word Search Python Medium Blind75, Grind75, Matrix, Graph
0082 Remove Duplicates from Sorted List II Python Medium
0083 Remove Duplicates from Sorted List Python Easy
0084 Largest Rectangle in Histogram Python Hard
0086 Partition List Python Medium
0088 Merge Sorted Array Python Easy
0091 Decode Ways Python Medium Blind75, Dynamic Programming
0092 Reverse Linked List II Python Medium
0094 Binary Tree Inorder Traversal Python Easy
0096 Unique Binary Search Trees Python Medium
0097 Interleaving String Python Medium Dynamic Programming
0098 Validate Binary Search Tree Python Medium Blind75, Grind75, Tree
0102 Binary Tree Level Order Traversal Python Medium Blind75, Grind75, BinaryTree
0105 Construct Binary Tree from Preorder and Inorder Traversal Python Medium Blind75, BinaryTree
0110 Balanced Binary Tree Python Easy Grind75, Binary Tree
0112 Path Sum Python Easy
0120 Triangle Python Medium Dynamic Programming
0121 Best Time to Buy and Sell Stock Python Easy Blind75, Grind75, Array
0125 Valid Palindrome Python Easy Blind75, Grind75, String
0131 Palindrome Partitioning Python Medium
0133 Clone Graph Python Medium Blind75, Grind75, Graph
0136 Single Number Python Easy
0138 Copy List with Random Pointer Python Medium Linked List
0139 Word Break Python Medium Grind75, Linked List, Tree
0141 Linked List Cycle Python Easy Grind75, Linked List
0142 Linked List Cycle II Python Medium
0146 LRU Cache Python Medium Grind75, Linked List
0148 Sort List Python Medium
0150 Evaluate Reverse Polish Notation Python Medium Grind75, Stack
0152 Maximum Product Subarray Python Medium Blind75, Array
0153 Find Minimum in Rotated Sorted Array Python Medium Blind75, Array
0155 Min Stack Python Medium Grind75, Stack
0160 Intersection of Two Linked Lists Python Easy
0167 Two Sum II - Input Array Is Sorted Python Medium
0169 Majority Element Python Easy Grind75, Array
0189 Rotate Array Python Medium
0191 Number of 1 Bits Python Easy Blind75, Binary
0198 House Robber Python Medium Blind75, Dynamic Programming
0200 Number of Islands Python Medium Blind75, Grind75, Graph
0202 Happy Number Python Easy
0203 Remove Linked List Elements Python Easy
0205 Isomorphic Strings Python Easy
0206 Reverse Linked List Python Easy Grind75, Linked List
0207 Course Schedule Python Medium Blind75, Grind75, Graph
0208 Implement Trie (Prefix Tree) Python Medium Blind75, Grind75, Tree
0210 Course Schedule II Python Medium
0213 House Robber II Python Medium Blind75, Dynamic Programming
0215 Kth Largest Element in an Array Python Medium Quick Select
0217 Contains Duplicate Python Easy Blind75, Grind75, Array
0221 Maximal Square Python Medium Top Down Memoization
0224 Basic Calculator Python Hard Grind75, Stack
0225 Implement Stack using Queues Python Easy
0226 Invert Binary Tree Python Easy Grind75, Binary Tree
0227 Basic Calculator II Python Medium
0228 Summary Ranges Python Easy
0229 Majority Element II Python Medium
0230 Kth Smallest Element in a BST Python Medium Blind75, Grind75, Binary Search Tree
0232 Implement Queue using Stacks Python Easy Grind75, Stack
0234 Palindrome Linked List Python Easy
0235 Lowest Common Ancestor of a Binary Search Tree Python Medium Grind75, Binary Search Tree
0238 Product of Array Except Self Python Medium Blind75, Grind75, Array
0242 Valid Anagram Python Easy Blind75, Grind75, String
0253 Meeting Rooms II Python Medium Blind75, Interval
0261 Graph Valid Tree Python Medium Blind75, Graph
0263 Ugly Number Python Easy
0279 Perfect Squares Python Medium Dynamic Programming
0283 Move Zeroes Python Easy
0287 Find the Duplicate Number Python Medium Floyd's Cycle Detection
0290 Word Pattern Python Easy
0300 Longest Increasing Subsequence Python Medium Blind75, Dynamic Programming
0316 Remove Duplicate Letters Python Medium
0322 Coin Change Python Medium Blind75, Grind75, Dynamic Programming
0323 Number of Connected Components in an Undirected Graph Python Medium Blind75, Graph, Union Find
0328 Odd Even Linked List Python Medium
0338 Counting Bits Python Easy Blind75, Binary
0341 Flatten Nested List Iterator Python Medium
0344 Reverse String Python Easy
0347 Top K Frequent Elements Python Medium Blind75, Heap, Bucket Sort
0349 Intersection of Two Arrays Python Easy
0350 Intersection of Two Arrays II Python Easy
0367 Valid Perfect Square Python Easy
0374 Guess Number Higher or Lower Python Easy
0383 Ransom Note Python Easy Grind75, Hash Table
0385 Mini Parser Python Medium
0387 First Unique Character in a String Python Easy
0394 Decode String Python Medium
0401 Binary Watch Python Easy
0402 Remove K Digits Python Medium
0409 Longest Palindrome Python Easy Grind75, String
0416 Partition Equal Subset Sum Python Medium Grind75, Dynamic Programming
0417 Pacific Atlantic Water Flow Python Medium Blind75, Graph
0419 Battleships in a Board Python Medium
0424 Longest Repeating Character Replacement Python Medium Blind75, String
0430 Flatten a Multilevel Doubly Linked List Python Medium
0438 Find All Anagrams in a String Python Medium Grind75, String
0441 Arranging Coins Python Easy
0442 Find All Duplicates in an Array Python Medium
0448 Find All Numbers Disappeared in an Array Python Easy
0456 132 Pattern Python Medium
0459 Repeated Substring Pattern Python Easy
0485 Max Consecutive Ones Python Easy
0496 Next Greater Element I Python Easy
0503 Next Greater Element II Python Medium
0543 Diameter of Binary Tree Python Medium Grind75, Binary Tree
0557 Reverse Words in a String III Python Easy
0560 Subarray Sum Equals K Python Medium Prefix Sums
0566 Reshape the Matrix Python Easy
0572 Subtree of Another Tree Python Easy Blind75, Tree
0575 Distribute Candies Python Easy
0594 Longest Harmonious Subsequence Python Easy
0599 Minimum Index Sum of Two Lists Python Easy
0605 Can Place Flowers Python Easy
0606 Construct String from Binary Tree Python Easy
0617 Merge Two Binary Trees Python Easy
0622 Design Circular Queue Python Medium
0647 Palindromic Substrings Python Medium Blind75, String
0657 Robot Return to Origin Python Easy
0667 Beautiful Arrangement II Python Medium
0680 Valid Palindrome II Python Easy
0682 Baseball Game Python Easy
0696 Count Binary Substrings Python Easy
0703 Kth Largest Element in a Stream Python Easy
0704 Binary Search Python Easy Grind75, Binary Search
0705 Design HashSet Python Easy
0706 Design HashMap Python Easy
0707 Design Linked List Python Medium
0724 Find Pivot Index Python Easy
0733 Flood Fill Python Easy Grind75, Graph
0739 Daily Temperatures Python Medium
0746 Min Cost Climbing Stairs Python Easy Blind75, Grind75, Dynamic Programming
0766 Toeplitz Matrix Python Easy
0771 Jewels and Stones Python Easy
0795 Number of Subarrays with Bounded Maximum Python Medium
0816 Ambiguous Coordinates Python Medium
0844 Backspace String Compare Python Easy
0845 Longest Mountain in Array Python Medium
0876 Middle of the Linked List Python Easy Grind75, Linked List
0880 Decoded String at Index Python Medium
0918 Maximum Sum Circular Subarray Python Medium
0929 Unique Email Addresses Python Easy
0949 Largest Time for Given Digits Python Medium
0953 Verifying an Alien Dictionary Python Easy
0977 Squares of a Sorted Array Python Easy
1041 Robot Bounded In Circle Python Medium Math & Geometry
1046 Last Stone Weight Python Easy
1047 Remove All Adjacent Duplicates In String Python Easy
1143 Longest Common Subsequence Python Medium Blind75, Dynamic Programming
1189 Maximum Number of Balloons Python Easy
1260 Shift 2D Grid Python Easy
1299 Replace Elements with Greatest Element on Right Side Python Easy
1332 Remove Palindromic Subsequences Python Easy
1375 Number of Times Binary String Is Prefix-Aligned Python Medium
1380 Lucky Numbers in a Matrix Python Easy
1408 String Matching in an Array Python Easy
1436 Destination City Python Easy
1448 Count Good Nodes in Binary Tree Python Medium
1466 Reorder Routes to Make All Paths Lead to the City Zero Python Medium
1502 Can Make Arithmetic Progression From Sequence Python Easy
1566 Detect Pattern of Length M Repeated K or More Times Python Easy
1576 Replace All ?'s to Avoid Consecutive Repeating Characters Python Easy
1588 Sum of All Odd Length Subarrays Python Easy
1638 Count Substrings That Differ by One Character Python Medium
1704 Determine if String Halves Are Alike Python Easy
1721 Swapping Nodes in a Linked List Python Medium
1748 Sum of Unique Elements Python Easy
1758 Minimum Changes To Make Alternating Binary String Python Easy
1763 Longest Nice Substring Python Easy
1773 Count Items Matching a Rule Python Easy
1779 Find Nearest Point That Has the Same X or Y Coordinate Python Easy
1784 Check if Binary String Has at Most One Segment of Ones Python Easy
1790 Check if One String Swap Can Make Strings Equal Python Easy
1796 Second Largest Digit in a String Python Easy
1805 Number of Different Integers in a String Python Easy
1812 Determine Color of a Chessboard Square Python Easy
1816 Truncate Sentence Python Easy
1822 Sign of the Product of an Array Python Easy
1832 Check if the Sentence Is Pangram Python Easy
1844 Replace All Digits with Characters Python Easy
1869 Longer Contiguous Segments of Ones than Zeros Python Easy
1880 Check if Word Equals Summation of Two Words Python Easy
1886 Determine Whether Matrix Can Be Obtained By Rotation Python Easy
1888 Minimum Number of Flips to Make the Binary String Alternating Python Medium Sliding Window
1911 Maximum Alternating Subsequence Sum Python Medium Dynamic Programming
1963 Minimum Number of Swaps to Make the String Balanced Python Medium
2028 Find Missing Observations Python Medium

About

Solutions to LeetCode


Languages

Language:Python 100.0%