Giter Club home page Giter Club logo

leetcode's Introduction

Leetcode

# Title Solution Runtime
1 Two Sum C++ 22 ms
2 Add Two Numbers Python3 42 ms
3 Longest Substring Without Repeating Characters Python3 55 ms
4 Median of Two Sorted Arrays C++ 36 ms
5 Longest Palindromic Substring Python3 281 ms
6 Zigzag Conversion Python3 48 ms
7 Reverse Integer Python3 29 ms
8 String to Integer (atoi) Python3 40 ms
9 Palindrome Number Python3 52 ms
10 Regular Expression Matching Python3 36 ms
11 Container With Most Water Python3 490 ms
12 Integer to Roman Python3 48 ms
13 Roman to Integer Python3 49 ms
14 Longest Common Prefix Python3 36 ms
15 3Sum Python3 865 ms
16 3Sum Closest Python3 369 ms
17 Letter Combinations of a Phone Number Python3 32 ms
18 4Sum Python3 788 ms
19 Remove Nth Node From End of List Python3 35 ms
20 Valid Parentheses Python3 54 ms
21 Merge Two Sorted Lists Python3 41 ms
22 Generate Parentheses Python3 32 ms
23 Merge k Sorted Lists Python3 116 ms
24 Swap Nodes in Pairs Python3 32 ms
25 Reverse Nodes in k-Group Python3 44 ms
26 Remove Duplicates from Sorted Array Python3 76 ms
27 Remove Element Python3 47 ms
28 Implement strStr() Python3 28 ms
29 Divide Two Integers Python3 20 ms
30 Substring with Concatenation of All Words Python3 77 ms
31 Next Permutation Python3 47 ms
32 Longest Valid Parentheses Python3 86 ms
33 Search in Rotated Sorted Array C++ 11 ms
34 Find First and Last Position of Element in Sorted Array Python3 80 ms
35 Search Insert Position Python3 68 ms
36 Valid Sudoku Python3 92 ms
37 Sudoku Solver Python3 208 ms
38 Count and Say Python3 44 ms
39 Combination Sum Python3 51 ms
41 First Missing Positive Python3 1329 ms
42 Trapping Rain Water Python3 60 ms
43 Multiply Strings Python3 242 ms
44 Wildcard Matching Python3 84 ms
45 Jump Game II Python3 120 ms
46 Permutations Python3 40 ms
47 Permutations II Python3 100 ms
48 Rotate Image Python3 40 ms
49 Group Anagrams Python3 104 ms
50 Pow(x, n) Python3 24 ms
51 N-Queens Python3 73 ms
52 N-Queens II Python3 83 ms
53 Maximum Subarray Python3 557 ms
54 Spiral Matrix Python3 31 ms
55 Jump Game Python3 492 ms
56 Merge Intervals C++ 37 ms
57 Insert Interval Python3 80 ms
58 Length of Last Word Python3 44 ms
59 Spiral Matrix II Python3 31 ms
60 Permutation Sequence Python3 57 ms
61 Rotate List Python3 36 ms
62 Unique Paths Python3 31 ms
63 Unique Paths II Python3 66 ms
64 Minimum Path Sum Python3 96 ms
66 Plus One C++ 0 ms
67 Add Binary Python3 36 ms
68 Text Justification Python3 65 ms
69 Sqrt(x) Python3 55 ms
70 Climbing Stairs Python3 55 ms
71 Simplify Path Python3 34 ms
72 Edit Distance Python3 247 ms
73 Set Matrix Zeroes Python3 145 ms
74 Search a 2D Matrix Python3 38 ms
75 Sort Colors Python3 44 ms
76 Minimum Window Substring Python3 141 ms
77 Combinations Python3 76 ms
78 Subsets Python3 35 ms
79 Word Search Python3 5833 ms
80 Remove Duplicates from Sorted Array II Python3 53 ms
81 Search in Rotated Sorted Array II Python3 44 ms
82 Remove Duplicates from Sorted List II Python3 40 ms
83 Remove Duplicates from Sorted List Python3 44 ms
84 Largest Rectangle in Histogram Python3 1296 ms
85 Maximal Rectangle Python3 471 ms
86 Partition List Python3 37 ms
88 Merge Sorted Array Python3 34 ms
89 Gray Code Python3 75 ms
90 Subsets II Python3 57 ms
91 Decode Ways Python3 36 ms
92 Reverse Linked List II Python3 37 ms
94 Binary Tree Inorder Traversal Python3 48 ms
95 Unique Binary Search Trees II Python3 61 ms
96 Unique Binary Search Trees Python3 64 ms
97 Interleaving String Python3 60 ms
98 Validate Binary Search Tree Python3 48 ms
99 Recover Binary Search Tree Python3 54 ms
100 Same Tree Python3 59 ms
101 Symmetric Tree Python3 32 ms
102 Binary Tree Level Order Traversal Python3 51 ms
103 Binary Tree Zigzag Level Order Traversal Python3 28 ms
104 Maximum Depth of Binary Tree Python3 39 ms
105 Construct Binary Tree from Preorder and Inorder Traversal Python3 52 ms
106 Construct Binary Tree from Inorder and Postorder Traversal Python3 50 ms
108 Convert Sorted Array to Binary Search Tree Python3 55 ms
109 Convert Sorted List to Binary Search Tree Python3 96 ms
110 Balanced Binary Tree Python3 81 ms
111 Minimum Depth of Binary Tree Python3 695 ms
112 Path Sum Python3 42 ms
113 Path Sum II Python3 40 ms
114 Flatten Binary Tree to Linked List Python3 36 ms
115 Distinct Subsequences Python3 72 ms
116 Populating Next Right Pointers in Each Node Python3 68 ms
117 Populating Next Right Pointers in Each Node II Python3 44 ms
118 Pascal's Triangle Python3 24 ms
119 Pascal's Triangle II Python3 32 ms
120 Triangle Python3 90 ms
121 Best Time to Buy and Sell Stock Python3 1032 ms
122 Best Time to Buy and Sell Stock II Python3 60 ms
123 Best Time to Buy and Sell Stock III Python3 1205 ms
124 Binary Tree Maximum Path Sum Python3 118 ms
125 Valid Palindrome Python3 40 ms
128 Longest Consecutive Sequence Python3 2588 ms
129 Sum Root to Leaf Numbers Python3 39 ms
130 Surrounded Regions Python3 124 ms
133 Clone Graph Python3 36 ms
134 Gas Station Python3 480 ms
136 Single Number C++ 30 ms
137 Single Number II Python3 52 ms
138 Copy List with Random Pointer Python3 29 ms
139 Word Break Python3 67 ms
141 Linked List Cycle Python3 52 ms
142 Linked List Cycle II Python3 48 ms
143 Reorder List Python3 96 ms
144 Binary Tree Preorder Traversal Python3 28 ms
145 Binary Tree Postorder Traversal Python3 20 ms
146 LRU Cache Python3 560 ms
148 Sort List Python3 548 ms
149 Max Points on a Line Python3 36 ms
150 Evaluate Reverse Polish Notation Python3 60 ms
151 Reverse Words in a String Python3 40 ms
152 Maximum Product Subarray Python3 52 ms
153 Find Minimum in Rotated Sorted Array C++ 4 ms
154 Find Minimum in Rotated Sorted Array II C++ 10 ms
155 Min Stack Python3 56 ms
157 Read N Characters Given Read4 Python3 49 ms
159 Longest Substring with At Most Two Distinct Characters Python3 212 ms
160 Intersection of Two Linked Lists Python3 160 ms
161 One Edit Distance Python3 61 ms
162 Find Peak Element C++ 0 ms
166 Fraction to Recurring Decimal Python3 42 ms
167 Two Sum II - Input Array Is Sorted Python3 100 ms
169 Majority Element Python3 171 ms
170 Two Sum III - Data structure design Python3 179 ms
173 Binary Search Tree Iterator Python3 96 ms
186 Reverse Words in a String II Python3 264 ms
187 Repeated DNA Sequences Python3 88 ms
188 Best Time to Buy and Sell Stock IV Python3 100 ms
189 Rotate Array Python3 163 ms
190 Reverse Bits Python3 32 ms
191 Number of 1 Bits Python3 36 ms
198 House Robber C++ 0 ms
199 Binary Tree Right Side View Python3 28 ms
200 Number of Islands Python3 230 ms
201 Bitwise AND of Numbers Range Python3 52 ms
202 Happy Number Python3 58 ms
203 Remove Linked List Elements Python3 68 ms
205 Isomorphic Strings C++ 2 ms
206 Reverse Linked List Python3 43 ms
207 Course Schedule Python3 133 ms
209 Minimum Size Subarray Sum Python3 185 ms
210 Course Schedule II Python3 170 ms
213 House Robber II Python3 60 ms
214 Shortest Palindrome Python3 88 ms
215 Kth Largest Element in an Array Python3 420 ms
216 Combination Sum III Python3 55 ms
217 Contains Duplicate Python3 811 ms
218 The Skyline Problem Python3 178 ms
219 Contains Duplicate II Python3 624 ms
220 Contains Duplicate III Python3 160 ms
221 Maximal Square Python3 208 ms
222 Count Complete Tree Nodes C++ 39 ms
224 Basic Calculator Python3 132 ms
225 Implement Stack using Queues Python3 28 ms
226 Invert Binary Tree Python3 12 ms
227 Basic Calculator II Python3 148 ms
229 Majority Element II Python3 120 ms
230 Kth Smallest Element in a BST Python3 58 ms
231 Power of Two Python3 32 ms
232 Implement Queue using Stacks Python3 24 ms
235 Lowest Common Ancestor of a Binary Search Tree Python3 72 ms
236 Lowest Common Ancestor of a Binary Tree Python3 43 ms
237 Delete Node in a Linked List Python3 40 ms
238 Product of Array Except Self Python3 236 ms
239 Sliding Window Maximum Python3 1776 ms
240 Search a 2D Matrix II Python3 222 ms
241 Different Ways to Add Parentheses Python3 43 ms
242 Valid Anagram Python3 40 ms
243 Shortest Word Distance Python3 68 ms
244 Shortest Word Distance II Python3 136 ms
245 Shortest Word Distance III Python3 983 ms
249 Group Shifted Strings Python3 36 ms
250 Count Univalue Subtrees Python3 62 ms
251 Flatten 2D Vector Python3 132 ms
252 Meeting Rooms Python3 71 ms
253 Meeting Rooms II Python3 80 ms
254 Factor Combinations Python3 133 ms
255 Verify Preorder Sequence in Binary Search Tree Python3 363 ms
256 Paint House Python3 78 ms
257 Binary Tree Paths Python3 40 ms
258 Add Digits Python3 36 ms
259 3Sum Smaller Python3 478 ms
261 Graph Valid Tree Python3 92 ms
263 Ugly Number Python3 32 ms
264 Ugly Number II Python3 171 ms
265 Paint House II Python3 344 ms
266 Palindrome Permutation Python3 28 ms
267 Palindrome Permutation II Python3 28 ms
268 Missing Number Python3 116 ms
269 Alien Dictionary Python3 46 ms
270 Closest Binary Search Tree Value Python3 43 ms
274 H-Index Python3 54 ms
276 Paint Fence Python3 73 ms
277 Find the Celebrity C++ 227 ms
278 First Bad Version C++ 3 ms
279 Perfect Squares Python3 551 ms
280 Wiggle Sort Python3 179 ms
281 Zigzag Iterator Python3 66 ms
283 Move Zeroes C++ 27 ms
284 Peeking Iterator Python3 61 ms
285 Inorder Successor in BST Python3 140 ms
286 Walls and Gates Python3 388 ms
287 Find the Duplicate Number Python3 582 ms
289 Game of Life Python3 61 ms
290 Word Pattern Python3 28 ms
295 Find Median from Data Stream Python3 410 ms
297 Serialize and Deserialize Binary Tree Python3 92 ms
298 Binary Tree Longest Consecutive Sequence C++ 44 ms
299 Bulls and Cows C++ 4 ms
300 Longest Increasing Subsequence Python3 60 ms
301 Remove Invalid Parentheses Python3 3651 ms
303 Range Sum Query - Immutable Python3 156 ms
304 Range Sum Query 2D - Immutable Python3 1895 ms
305 Number of Islands II Python3 1004 ms
306 Additive Number C++ 2 ms
307 Range Sum Query - Mutable Python3 2431 ms
309 Best Time to Buy and Sell Stock with Cooldown Python3 2000 ms
310 Minimum Height Trees Python3 585 ms
311 Sparse Matrix Multiplication Python3 60 ms
314 Binary Tree Vertical Order Traversal Python3 35 ms
315 Count of Smaller Numbers After Self Python3 3995 ms
316 Remove Duplicate Letters C++ 7 ms
317 Shortest Distance from All Buildings Python3 4445 ms
318 Maximum Product of Word Lengths Python3 312 ms
320 Generalized Abbreviation Python3 124 ms
321 Create Maximum Number Python3 792 ms
322 Coin Change Python3 2326 ms
323 Number of Connected Components in an Undirected Graph Python3 132 ms
324 Wiggle Sort II Python3 370 ms
325 Maximum Size Subarray Sum Equals k Python3 548 ms
326 Power of Three Python3 68 ms
328 Odd Even Linked List Python3 84 ms
329 Longest Increasing Path in a Matrix Python3 310 ms
332 Reconstruct Itinerary Python3 110 ms
333 Largest BST Subtree Python3 68 ms
334 Increasing Triplet Subsequence Python3 560 ms
337 House Robber III Python3 72 ms
338 Counting Bits Python3 127 ms
339 Nested List Weight Sum Python3 28 ms
340 Longest Substring with At Most K Distinct Characters Python3 53 ms
341 Flatten Nested List Iterator Python3 120 ms
342 Power of Four Python3 24 ms
343 Integer Break Python3 36 ms
344 Reverse String Python3 196 ms
345 Reverse Vowels of a String Python3 58 ms
347 Top K Frequent Elements Python3 87 ms
348 Design Tic-Tac-Toe Python3 88 ms
349 Intersection of Two Arrays Python3 40 ms
350 Intersection of Two Arrays II Python3 44 ms
355 Design Twitter Python3 44 ms
357 Count Numbers with Unique Digits Python3 32 ms
358 Rearrange String k Distance Apart Python3 65 ms
360 Sort Transformed Array Python3 73 ms
366 Find Leaves of Binary Tree Python3 32 ms
367 Valid Perfect Square C++ 3 ms
369 Plus One Linked List Python3 61 ms
371 Sum of Two Integers Python3 26 ms
372 Super Pow Python3 84 ms
373 Find K Pairs with Smallest Sums Python3 1032 ms
374 Guess Number Higher or Lower C++ 0 ms
375 Guess Number Higher or Lower II C++ 10 ms
376 Wiggle Subsequence Python3 38 ms
377 Combination Sum IV Python3 57 ms
378 Kth Smallest Element in a Sorted Matrix Python3 218 ms
379 Design Phone Directory Python3 127 ms
380 Insert Delete GetRandom O(1) Python3 508 ms
383 Ransom Note Python3 44 ms
384 Shuffle an Array Python3 252 ms
386 Lexicographical Numbers Python3 92 ms
387 First Unique Character in a String Python3 100 ms
388 Longest Absolute File Path Python3 32 ms
389 Find the Difference Python3 43 ms
392 Is Subsequence Python3 32 ms
394 Decode String Python3 32 ms
395 Longest Substring with At Least K Repeating Characters Python3 228 ms
398 Random Pick Index Python3 308 ms
399 Evaluate Division Python3 50 ms
401 Binary Watch Python3 28 ms
402 Remove K Digits Python3 68 ms
404 Sum of Left Leaves Python3 36 ms
408 Valid Word Abbreviation Python3 34 ms
409 Longest Palindrome Python3 24 ms
410 Split Array Largest Sum Python3 3418 ms
412 Fizz Buzz Python3 59 ms
413 Arithmetic Slices Python3 42 ms
414 Third Maximum Number C++ 8 ms
415 Add Strings C++ 6 ms
417 Pacific Atlantic Water Flow Python3 386 ms
421 Maximum XOR of Two Numbers in an Array Python3 1227 ms
422 Valid Word Square Python 28 ms
424 Longest Repeating Character Replacement Python3 158 ms
426 Convert Binary Search Tree to Sorted Doubly Linked List Python3 37 ms
429 N-ary Tree Level Order Traversal Python3 70 ms
430 Flatten a Multilevel Doubly Linked List Python3 33 ms
435 Non-overlapping Intervals Python3 1424 ms
437 Path Sum III Python3 43 ms
438 Find All Anagrams in a String Python3 109 ms
445 Add Two Numbers II Python3 63 ms
448 Find All Numbers Disappeared in an Array C++ 182 ms
449 Serialize and Deserialize BST Python3 55 ms
450 Delete Node in a BST Python3 64 ms
451 Sort Characters By Frequency Python3 65 ms
452 Minimum Number of Arrows to Burst Balloons Python3 1260 ms
453 Minimum Moves to Equal Array Elements Python3 248 ms
454 4Sum II Python3 1063 ms
456 132 Pattern Python3 623 ms
459 Repeated Substring Pattern Python3 47 ms
461 Hamming Distance Python3 28 ms
463 Island Perimeter Python3 452 ms
475 Heaters C++ 47 ms
477 Total Hamming Distance Python3 981 ms
485 Max Consecutive Ones C++ 113 ms
486 Predict the Winner Python3 53 ms
487 Max Consecutive Ones II Python3 285 ms
495 Teemo Attacking Python3 260 ms
496 Next Greater Element I Python3 59 ms
498 Diagonal Traverse Python3 184 ms
500 Keyboard Row Python3 32 ms
501 Find Mode in Binary Search Tree Python3 56 ms
503 Next Greater Element II Python3 224 ms
509 Fibonacci Number Python3 24 ms
516 Longest Palindromic Subsequence Python3 1723 ms
518 Coin Change 2 Python3 387 ms
523 Continuous Subarray Sum Python3 825 ms
524 Longest Word in Dictionary through Deleting Python3 138 ms
525 Contiguous Array Python3 1199 ms
526 Beautiful Arrangement Python3 2080 ms
528 Random Pick with Weight Python3 167 ms
529 Minesweeper Python3 145 ms
530 Minimum Absolute Difference in BST C++ 17 ms
535 Encode and Decode TinyURL Python3 49 ms
538 Convert BST to Greater Tree Python3 76 ms
541 Reverse String II Python3 32 ms
542 01 Matrix Python3 925 ms
543 Diameter of Binary Tree Python3 49 ms
545 Boundary of Binary Tree Python3 40 ms
547 Number of Provinces Python3 338 ms
548 Split Array with Equal Sum Python3 3234 ms
556 Next Greater Element III Python3 40 ms
557 Reverse Words in a String III Python3 76 ms
560 Subarray Sum Equals K Python3 N/A
566 Reshape the Matrix Python3 80 ms
567 Permutation in String Python3 93 ms
572 Subtree of Another Tree Python3 152 ms
581 Shortest Unsorted Continuous Subarray Python3 353 ms
582 Kill Process Python3 500 ms
583 Delete Operation for Two Strings Python3 253 ms
589 N-ary Tree Preorder Traversal Python3 66 ms
590 N-ary Tree Postorder Traversal Python3 89 ms
593 Valid Square Python3 58 ms
605 Can Place Flowers Python3 172 ms
606 Construct String from Binary Tree Python3 53 ms
617 Merge Two Binary Trees Python3 80 ms
622 Design Circular Queue Python3 61 ms
628 Maximum Product of Three Numbers Python3 240 ms
633 Sum of Square Numbers C++ 0 ms
643 Maximum Average Subarray I Python3 808 ms
645 Set Mismatch Python3 161 ms
647 Palindromic Substrings Python3 280 ms
653 Two Sum IV - Input is a BST Python3 68 ms
658 Find K Closest Elements C++ 48 ms
659 Split Array into Consecutive Subsequences Python3 516 ms
669 Trim a Binary Search Tree Python3 49 ms
670 Maximum Swap Python3 28 ms
673 Number of Longest Increasing Subsequence Python3 1863 ms
680 Valid Palindrome II Python3 105 ms
682 Baseball Game Python3 44 ms
687 Longest Univalue Path Python3 529 ms
691 Stickers to Spell Word Python3 2536 ms
692 Top K Frequent Words Python3 59 ms
693 Binary Number with Alternating Bits Python3 41 ms
694 Number of Distinct Islands Python3 148 ms
695 Max Area of Island Python3 154 ms
697 Degree of an Array Python3 338 ms
700 Search in a Binary Search Tree Python3 68 ms
701 Insert into a Binary Search Tree Python3 140 ms
702 Search in a Sorted Array of Unknown Size C++ 36 ms
703 Kth Largest Element in a Stream Python3 9759 ms
704 Binary Search C++ 41 ms
705 Design HashSet Python3 231 ms
706 Design HashMap Python3 340 ms
707 Design Linked List Python3 222 ms
708 Insert into a Sorted Circular Linked List Python3 43 ms
709 To Lower Case Python3 36 ms
712 Minimum ASCII Delete Sum for Two Strings Python3
713 Subarray Product Less Than K Python3 500 ms
714 Best Time to Buy and Sell Stock with Transaction Fee Python3 1470 ms
716 Max Stack Python3 194 ms
717 1-bit and 2-bit Characters Python3 44 ms
718 Maximum Length of Repeated Subarray Python3 4972 ms
721 Accounts Merge Python3 208 ms
724 Find Pivot Index Python3 120 ms
729 My Calendar I Python3 307 ms
733 Flood Fill Python3 117 ms
735 Asteroid Collision Python3 88 ms
739 Daily Temperatures Python3 1244 ms
740 Delete and Earn Python3 110 ms
741 Cherry Pickup Python3 772 ms
743 Network Delay Time Python3 696 ms
744 Find Smallest Letter Greater Than Target Python3 101 ms
746 Min Cost Climbing Stairs Python3 44 ms
752 Open the Lock Python3 1204 ms
759 Employee Free Time Python3 89 ms
760 Find Anagram Mappings Python3 44 ms
762 Prime Number of Set Bits in Binary Representation Python3 299 ms
763 Partition Labels Python3 36 ms
764 Largest Plus Sign Python3 1900 ms
766 Toeplitz Matrix Python3 84 ms
767 Reorganize String Python3 34 ms
771 Jewels and Stones Python3 32 ms
784 Letter Case Permutation Python3 44 ms
787 Cheapest Flights Within K Stops Python3 105 ms
791 Custom Sort String Python3 34 ms
794 Valid Tic-Tac-Toe State Python3 16 ms
797 All Paths From Source to Target Python3 239 ms
802 Find Eventual Safe States Python3 710 ms
825 Friends Of Appropriate Ages Python3 287 ms
829 Consecutive Numbers Sum Python3 225 ms
833 Find And Replace in String Python3 60 ms
840 Magic Squares In Grid Python3 53 ms
841 Keys and Rooms Python3 60 ms
844 Backspace String Compare Python3 28 ms
852 Peak Index in a Mountain Array Python3 68 ms
853 Car Fleet Python3 912 ms
860 Lemonade Change Python3 913 ms
862 Shortest Subarray with Sum at Least K Python3 1881 ms
863 All Nodes Distance K in Binary Tree Python3 30 ms
865 Smallest Subtree with all the Deepest Nodes Python3 39 ms
867 Transpose Matrix Python3 72 ms
869 Reordered Power of 2 Python3 32 ms
870 Advantage Shuffle Python3 854 ms
876 Middle of the Linked List Python3 77 ms
877 Stone Game Python3 415 ms
885 Spiral Matrix III Python3 115 ms
886 Possible Bipartition Python3 973 ms
894 All Possible Full Binary Trees Python3 368 ms
896 Monotonic Array Python3 1449 ms
897 Increasing Order Search Tree Python3 39 ms
901 Online Stock Span Python3 605 ms
904 Fruit Into Baskets Python3 604 ms
905 Sort Array By Parity C++ 8 ms
907 Sum of Subarray Minimums Python3 770 ms
908 Smallest Range I Python3 136 ms
910 Smallest Range II Python3 188 ms
912 Sort an Array Python3 671 ms
918 Maximum Sum Circular Subarray Python3 365 ms
923 3Sum With Multiplicity Python3 149 ms
925 Long Pressed Name Python3 61 ms
929 Unique Email Addresses Python3 80 ms
931 Minimum Falling Path Sum Python3 142 ms
938 Range Sum of BST Python3 114 ms
941 Valid Mountain Array C++ 28 ms
946 Validate Stack Sequences Python3 64 ms
953 Verifying an Alien Dictionary Python3 42 ms
958 Check Completeness of a Binary Tree Python3 54 ms
968 Binary Tree Cameras Python3 40 ms
973 K Closest Points to Origin Python3 586 ms
974 Subarray Sums Divisible by K Python3 224 ms
976 Largest Perimeter Triangle Python3 203 ms
977 Squares of a Sorted Array C++ 54 ms
979 Distribute Coins in Binary Tree Python3 67 ms
980 Unique Paths III Python3 100 ms
983 Minimum Cost For Tickets Python3 85 ms
986 Interval List Intersections C++ 18 ms
989 Add to Array-Form of Integer Python3 288 ms
990 Satisfiability of Equality Equations Python3 44 ms
993 Cousins in Binary Tree Python3 28 ms
994 Rotting Oranges Python3 52 ms
997 Find the Town Judge C++ 202 ms
1003 Check If Word Is Valid After Substitutions Python3 32 ms
1004 Max Consecutive Ones III Python3 448 ms
1010 Pairs of Songs With Total Durations Divisible by 60 Python3 387 ms
1011 Capacity To Ship Packages Within D Days Python3 1076 ms
1014 Best Sightseeing Pair Python3 738 ms
1022 Sum of Root To Leaf Binary Numbers Python3 36 ms
1024 Video Stitching Python3 70 ms
1044 Longest Duplicate Substring Python3 4291 ms
1046 Last Stone Weight Python3 24 ms
1047 Remove All Adjacent Duplicates In String Python3 59 ms
1048 Longest String Chain Python3 132 ms
1051 Height Checker C++ 0 ms
1053 Previous Permutation With One Swap C++ 14 ms
1059 All Paths from Source Lead to Destination Python3 296 ms
1060 Missing Element in Sorted Array Python3 330 ms
1062 Longest Repeating Substring Python3 71 ms
1086 High Five Python3 76 ms
1087 Brace Expansion Python3 36 ms
1091 Shortest Path in Binary Matrix Python3 362 ms
1099 Two Sum Less Than K Python3 43 ms
1101 The Earliest Moment When Everyone Become Friends Python3 112 ms
1114 Print in Order Python3 77 ms
1115 Print FooBar Alternately Python3 93 ms
1116 Print Zero Even Odd Python3 78 ms
1119 Remove Vowels from a String Python3 27 ms
1122 Relative Sort Array Python3 46 ms
1123 Lowest Common Ancestor of Deepest Leaves Python3 103 ms
1124 Longest Well-Performing Interval Python3 220 ms
1130 Minimum Cost Tree From Leaf Values Python3 46 ms
1135 Connecting Cities With Minimum Cost Python3 754 ms
1136 Parallel Courses Python3 404 ms
1137 N-th Tribonacci Number Python3 44 ms
1143 Longest Common Subsequence Python3 1670 ms
1151 Minimum Swaps to Group All 1's Together Python3 896 ms
1163 Last Substring in Lexicographical Order Python3 545 ms
1167 Minimum Cost to Connect Sticks Python3 316 ms
1168 Optimize Water Distribution in a Village Python3 624 ms
1182 Shortest Distance to Target Color Python3 2503 ms
1188 Design Bounded Blocking Queue Python3 55 ms
1192 Critical Connections in a Network Python3 4126 ms
1197 Minimum Knight Moves Python3 4630 ms
1201 Ugly Number III Python3 42 ms
1202 Smallest String With Swaps Python3 1053 ms
1209 Remove All Adjacent Duplicates in String II Python3 79 ms
1213 Intersection of Three Sorted Arrays Python3 80 ms
1214 Two Sum BSTs Python3 138 ms
1218 Longest Arithmetic Subsequence of Given Difference Python3 524 ms
1221 Split a String in Balanced Strings Python3 32 ms
1228 Missing Number In Arithmetic Progression Python3 59 ms
1229 Meeting Scheduler Python3 1031 ms
1230 Toss Strange Coins Python3 1125 ms
1231 Divide Chocolate Python3 371 ms
1232 Check If It Is a Straight Line Python3 112 ms
1239 Maximum Length of a Concatenated String with Unique Characters Python3 96 ms
1248 Count Number of Nice Subarrays Python3 976 ms
1249 Minimum Remove to Make Valid Parentheses Python3 83 ms
1260 Shift 2D Grid Python3 229 ms
1281 Subtract the Product and Sum of Digits of an Integer Python3 38 ms
1289 Minimum Falling Path Sum II Python3 912 ms
1290 Convert Binary Number in a Linked List to Integer Python3 64 ms
1291 Sequential Digits Python3 28 ms
1295 Find Numbers with Even Number of Digits C++ 7 ms
1299 Replace Elements with Greatest Element on Right Side C++ 122 ms
1300 Sum of Mutated Array Closest to Target Python3 155 ms
1305 All Elements in Two Binary Search Trees Python3 555 ms
1306 Jump Game III Python3 300 ms
1309 Decrypt String from Alphabet to Integer Mapping Python3 28 ms
1314 Matrix Block Sum Python3 151 ms
1319 Number of Operations to Make Network Connected Python3 778 ms
1325 Delete Leaves With a Given Value Python3 75 ms
1326 Minimum Number of Taps to Open to Water a Garden Python3 173 ms
1329 Sort the Matrix Diagonally Python3 80 ms
1337 The K Weakest Rows in a Matrix Python3 108 ms
1340 Jump Game V Python3 490 ms
1345 Jump Game IV Python3 552 ms
1346 Check If N and Its Double Exist C++ 6 ms
1351 Count Negative Numbers in a Sorted Matrix Python3 177 ms
1356 Sort Integers by The Number of 1 Bits Python3 121 ms
1365 How Many Numbers Are Smaller Than the Current Number Python3 104 ms
1367 Linked List in Binary Tree Python3 97 ms
1368 Minimum Cost to Make at Least One Valid Path in a Grid Python3 404 ms
1394 Find Lucky Integer in an Array Python3 87 ms
1396 Design Underground System Python3 267 ms
1427 Perform String Shifts Python3 20 ms
1469 Find All The Lonely Nodes Python3 59 ms
1474 Delete N Nodes After M Nodes of a Linked List Python3 68 ms
1482 Minimum Number of Days to Make m Bouquets Python3 2062 ms
1491 Average Salary Excluding the Minimum and Maximum Salary Python3 60 ms
1498 Number of Subsequences That Satisfy the Given Sum Condition Python3 503 ms
1502 Can Make Arithmetic Progression From Sequence Python3 47 ms
1512 Number of Good Pairs Python3 31 ms
1522 Diameter of N-Ary Tree Python3 58 ms
1523 Count Odd Numbers in an Interval Range Python3 49 ms
1533 Find the Index of the Large Integer Python3 257 ms
1557 Minimum Number of Vertices to Reach All Nodes Python3 1156 ms
1566 Detect Pattern of Length M Repeated K or More Times Python3 32 ms
1567 Maximum Length of Subarray With Positive Product Python3 858 ms
1570 Dot Product of Two Sparse Vectors Python3 1286 ms
1572 Matrix Diagonal Sum Python3 112 ms
1573 Number of Ways to Split a String Python3 453 ms
1584 Min Cost to Connect All Points Python3 1178 ms
1586 Binary Search Tree Iterator II Python3 444 ms
1588 Sum of All Odd Length Subarrays Python3 65 ms
1592 Rearrange Spaces Between Words Python3 62 ms
1598 Crawler Log Folder Python3 57 ms
1602 Find Nearest Right Node in Binary Tree Python3 507 ms
1603 Design Parking System Python3 163 ms
1630 Arithmetic Subarrays Python3 375 ms
1631 Path With Minimum Effort Python3 1038 ms
1634 Add Two Polynomials Represented as Linked Lists Python3 897 ms
1642 Furthest Building You Can Reach Python3 636 ms
1644 Lowest Common Ancestor of a Binary Tree II Python3 132 ms
1650 Lowest Common Ancestor of a Binary Tree III Python3 51 ms
1652 Defuse the Bomb Python3 44 ms
1657 Determine if Two Strings Are Close Python3 135 ms
1658 Minimum Operations to Reduce X to Zero Python3 832 ms
1660 Correct a Binary Tree Python3 184 ms
1668 Maximum Repeating Substring Python3 28 ms
1672 Richest Customer Wealth Python3 71 ms
1676 Lowest Common Ancestor of a Binary Tree IV Python3 2079 ms
1678 Goal Parser Interpretation Python3 33 ms
1695 Maximum Erasure Value Python3 1248 ms
1696 Jump Game VI Python3 1405 ms
1701 Average Waiting Time Python3 920 ms
1718 Construct the Lexicographically Largest Valid Sequence Python3 N/A
1720 Decode XORed Array Python3 216 ms
1721 Swapping Nodes in a Linked List Python3 1020 ms
1727 Largest Submatrix With Rearrangements Python3 1328 ms
1730 Shortest Path to Get Food Python3 500 ms
1738 Find Kth Largest XOR Coordinate Value Python3 5391 ms
1740 Find Distance in a Binary Tree Python3 67 ms
1746 Maximum Subarray Sum After One Operation Python3 1256 ms
1762 Buildings With an Ocean View Python3 490 ms
1768 Merge Strings Alternately Python3 38 ms
1779 Find Nearest Point That Has the Same X or Y Coordinate Python3 744 ms
1780 Check if Number is a Sum of Powers of Three Python3 32 ms
1790 Check if One String Swap Can Make Strings Equal Python3 32 ms
1822 Sign of the Product of an Array Python3 78 ms
1823 Find the Winner of the Circular Game Python3 40 ms
1836 Remove Duplicates From an Unsorted Linked List Python3 1624 ms
1845 Seat Reservation Manager Python3 997 ms
1868 Product of Two Run-Length Encoded Arrays Python3 4507 ms
1874 Minimize Product Sum of Two Arrays Python3 1292 ms
1886 Determine Whether Matrix Can Be Obtained By Rotation Python3 44 ms
1891 Cutting Ribbons Python3 2408 ms
1901 Find a Peak Element II Python3 2015 ms
1920 Build Array from Permutation C++ 13 ms
1922 Count Good Numbers Python3 30 ms
1926 Nearest Exit from Entrance in Maze Python3 630 ms
1940 Longest Common Subsequence Between Sorted Arrays Python3 286 ms
1945 Sum of Digits of String After Convert Python3 51 ms
1947 Maximum Compatibility Score Sum Python3 472 ms
1963 Minimum Number of Swaps to Make the String Balanced Python3 316 ms
1969 Minimum Non-Zero Product of the Array Elements C++ 3 ms
1971 Find if Path Exists in Graph Python3 2472 ms
1973 Count Nodes Equal to Sum of Descendants Python3 943 ms
1980 Find Unique Binary String Python3 34 ms
1985 Find the Kth Largest Integer in the Array Python3 408 ms
1991 Find the Middle Index in Array Python3 50 ms
1992 Find All Groups of Farmland Python3 798 ms
1995 Count Special Quadruplets Python3 112 ms
1996 The Number of Weak Characters in the Game C++ 761 ms
2007 Find Original Array From Doubled Array C++ 396 ms
2015 Average Height of Buildings in Each Segment C++ 294 ms
2016 Maximum Difference Between Increasing Elements Python3 36 ms
2021 Brightest Position on Street C++ 251 ms
2022 Convert 1D Array Into 2D Array Python3 1008 ms
2023 Number of Pairs of Strings With Concatenation Equal to Target Python3 40 ms
2024 Maximize the Confusion of an Exam Python3 1295 ms
2031 Count Subarrays With More Ones Than Zeros Python3 1258 ms
2034 Stock Price Fluctuation Python3 911 ms
2038 Remove Colored Pieces if Both Neighbors are the Same Color Python3 178 ms
2054 Two Best Non-Overlapping Events Python3 1708 ms
2059 Minimum Operations to Convert Number Python3 6494 ms
2067 Number of Equal Count Substrings Python3 1028 ms
2071 Maximum Number of Tasks You Can Assign Python3 6651 ms
2076 Process Restricted Friend Requests Python3 252 ms
2078 Two Furthest Houses With Different Colors Python3 70 ms
2081 Sum of k-Mirror Numbers Python3 3861 ms
2083 Substrings That Begin and End With the Same Letter Python3 86 ms
2086 Minimum Number of Food Buckets to Feed the Hamsters C++ 14 ms
2087 Minimum Cost Homecoming of a Robot in a Grid Python3 1706 ms
2090 K Radius Subarray Averages Python3 1083 ms
2092 Find All People With Secret Python3 3694 ms
2096 Step-By-Step Directions From a Binary Tree Node to Another Python3 609 ms
2097 Valid Arrangement of Pairs Python3 2808 ms
2101 Detonate the Maximum Bombs Python3 608 ms
2104 Sum of Subarray Ranges Python3 192 ms
2105 Watering Plants II Python3 1409 ms
2108 Find First Palindromic String in the Array C++ 36 ms
2109 Adding Spaces to a String C++ 153 ms
2115 Find All Possible Recipes from Given Supplies Python3 1073 ms
2116 Check if a Parentheses String Can Be Valid Python3 410 ms
2125 Number of Laser Beams in a Bank Python3 432 ms
2128 Remove All Ones With Row and Column Flips Python3 432 ms
2130 Maximum Twin Sum of a Linked List Python3 1536 ms
2131 Longest Palindrome by Concatenating Two Letter Words Python3 1658 ms
2133 Check if Every Row and Column Contains All Numbers Python3 556 ms
2138 Divide a String Into Groups of Size k Python3 55 ms
2139 Minimum Moves to Reach Target Score Python3 42 ms
2140 Solving Questions With Brainpower Python3 1856 ms
2149 Rearrange Array Elements by Sign Python3 2374 ms
2150 Find All Lonely Numbers in the Array Python3 1452 ms
2155 All Divisions With the Highest Score of a Binary Array Python3 3960 ms
2156 Find Substring With Given Hash Value Python3 570 ms
2166 Design Bitset Python3 1844 ms
2174 Remove All Ones With Row and Column Flips II Python3 64 ms
2210 Count Hills and Valleys in an Array Python3 44 ms
2218 Maximum Value of K Coins From Piles Python3 6008 ms
2229 Check if an Array Is Consecutive C++ 107 ms
2235 Add Two Integers Python3 45 ms
2237 Count Positions on Street With Required Brightness C++ 232 ms
2256 Minimum Average Difference C++ N/A
2265 Count Nodes Equal to Average of Subtree C++ 3 ms
2289 Steps to Make Array Non-decreasing C++ 130 ms
2305 Fair Distribution of Cookies C++ 6 ms
2319 Check if Matrix Is X-Matrix C++ 76 ms
2330 Valid Palindrome IV Python3 49 ms
2342 Max Sum of a Pair With Equal Sum of Digits Python3 908 ms
2365 Task Scheduler II C++ 256 ms
2379 Minimum Recolors to Get K Consecutive Black Blocks Python3 52 ms
2452 Words Within Two Edits of Dictionary C++ 21 ms
2461 Maximum Sum of Distinct Subarrays With Length K C++ 186 ms
2476 Closest Nodes Queries in a Binary Search Tree C++ 385 ms
2487 Remove Nodes From Linked List Python3 418 ms
2498 Frog Jump II C++ 164 ms
2531 Make Number of Distinct Characters Equal C++ 44 ms
2536 Increment Submatrices by One Python3 1016 ms
2553 Separate the Digits in an Array C++ 8 ms
2595 Number of Even and Odd Bits Python3 33 ms
2596 Check Knight Tour Configuration Python3 11 ms
2597 The Number of Beautiful Subsets Python3 350 ms
2611 Mice and Cheese Python3 637 ms
2667 Create Hello World Function JavaScript 57 ms
2762 Continuous Subarrays Python3 570 ms
2810 Faulty Keyboard Python3 49 ms
2824 Count Pairs Whose Sum is Less than Target Python3 55 ms
2848 Points That Intersect With Cars Python3 75 ms
2933 High-Access Employees Python3 167 ms
2956 Find Common Elements Between Two Arrays Python3 117 ms
2962 Count Subarrays Where Max Element Appears at Least K Times Python3 860 ms
3101 Count Alternating Subarrays Python3 787 ms
3164 Find the Number of Good Pairs II Python3 1002 ms
3201 Find the Maximum Length of Valid Subsequence I Python3 928 ms
3202 Find the Maximum Length of Valid Subsequence II Python3 4946 ms

leetcode's People

Contributors

karrywong avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.